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

Commit 90d284ca authored by Treehugger Robot's avatar Treehugger Robot Committed by Gerrit Code Review
Browse files

Merge "Set EDITED column to USER_EDITED when editing APN"

parents f05fc290 a05db0fa
Loading
Loading
Loading
Loading
+8 −2
Original line number Diff line number Diff line
@@ -249,7 +249,9 @@ public class ApnEditor extends SettingsPreferenceFragment
                    finish();
                    return;
                }
                mUri = getContentResolver().insert(uri, new ContentValues());
                ContentValues contentValues = new ContentValues();
                contentValues.put(Telephony.Carriers.EDITED, Telephony.Carriers.USER_EDITED);
                mUri = getContentResolver().insert(uri, contentValues);
            } else {
                mUri = ContentUris.withAppendedId(Telephony.Carriers.CONTENT_URI,
                        icicle.getInt(SAVED_POS));
@@ -464,7 +466,9 @@ public class ApnEditor extends SettingsPreferenceFragment
        if (mUri == null && mNewApn) {
            // The URI could have been deleted when activity is paused,
            // therefore, it needs to be restored.
            mUri = getContentResolver().insert(getIntent().getData(), new ContentValues());
            ContentValues contentValues = new ContentValues();
            contentValues.put(Telephony.Carriers.EDITED, Telephony.Carriers.USER_EDITED);
            mUri = getContentResolver().insert(getIntent().getData(), contentValues);
            if (mUri == null) {
                Log.w(TAG, "Failed to insert new telephony provider into "
                        + getIntent().getData());
@@ -1044,6 +1048,8 @@ public class ApnEditor extends SettingsPreferenceFragment
                callUpdate,
                CARRIER_ENABLED_INDEX);

        values.put(Telephony.Carriers.EDITED, Telephony.Carriers.USER_EDITED);

        if (callUpdate) {
            getContentResolver().update(mUri, values, null, null);
        } else {