Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 0f619fea authored by narinder Rana's avatar narinder Rana
Browse files

refine code

parent f707f528
Loading
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -37,10 +37,10 @@ class AutoDeleteDialog(context: Activity, listener: (Int) -> Unit) : AlertDialog
        setButton(DialogInterface.BUTTON_NEUTRAL, context.getString(R.string.button_cancel)) { _, _ -> }
        setButton(DialogInterface.BUTTON_NEGATIVE, context.getString(R.string.settings_auto_delete_never)) { _, _ -> listener(0) }
        setButton(DialogInterface.BUTTON_POSITIVE, context.getString(R.string.button_save)) { _, _ ->
            if (!layout.field.text.toString().isEmpty()) {
            if (!layout.field.text.toString().trim().isEmpty()) {
                listener(layout.field.text.toString().toIntOrNull() ?: 0)
            } else {
                Toast.makeText(context, "Not able to add empty number ! please try again", Toast.LENGTH_LONG).show()
                Toast.makeText(context, context.getString(R.string.not_able_to_add_empty_number), Toast.LENGTH_LONG).show()
            }
        }
    }
+1 −0
Original line number Diff line number Diff line
@@ -502,4 +502,5 @@
    <string name="rate_summary">Share some love and rate us on Google Play!</string>
    <string name="rate_okay">OKAY!</string>
    <string name="rate_dismiss">DISMISS</string>
    <string name="not_able_to_add_empty_number">Not able to add empty number ! please try again</string>
</resources>