diff options
author | Makoto Onuki <omakoto@google.com> | 2017-06-05 13:49:04 -0700 |
---|---|---|
committer | Makoto Onuki <omakoto@google.com> | 2017-06-05 13:49:04 -0700 |
commit | f752e4fbe36b30346c33c97a12ed7bb2bcf4256c (patch) | |
tree | 5de4ab9595e840f53826e7908344b92e5435081c /src | |
parent | 544cb78646d1631f502762ac52594ea8d478b1d6 (diff) | |
download | ContactsProvider-f752e4fbe36b30346c33c97a12ed7bb2bcf4256c.tar.gz |
Allow updating TIMES_CONTACTED again.android-vts-8.0_r2android-vts-8.0_r1oreo-dev
Explicitly setting to TIMES_CONTACTED was allowed on pre-N builds.
We tried to disable it for O, but turned out some system apps are using it.
Let's re-open it.
Test: adb shell am instrument -w com.android.providers.contacts.tests
Test: adb shell am instrument -w -e package android.provider.cts.contacts android.provider.cts/android.support.test.runner.AndroidJUnitRunner
Bug: 35321783
Change-Id: I07af087256cc9908b031bd8dfbd9fad479d4681f
Diffstat (limited to 'src')
-rw-r--r-- | src/com/android/providers/contacts/ContactsProvider2.java | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/com/android/providers/contacts/ContactsProvider2.java b/src/com/android/providers/contacts/ContactsProvider2.java index 69b87cf2..7d626aee 100644 --- a/src/com/android/providers/contacts/ContactsProvider2.java +++ b/src/com/android/providers/contacts/ContactsProvider2.java @@ -4529,10 +4529,9 @@ public class ContactsProvider2 extends AbstractContactsProvider ContactsDatabaseHelper.copyLongValue( ret, Contacts.RAW_LAST_TIME_CONTACTED, ret, Contacts.LR_LAST_TIME_CONTACTED); - if (ret.containsKey(Contacts.LR_TIMES_CONTACTED)) { - Log.w(TAG, "Column '" + Contacts.LR_TIMES_CONTACTED + "' can no longer be modified" - + " directly, ignored. Caller=" + getCallingPackage()); - } + ContactsDatabaseHelper.copyLongValue( + ret, Contacts.RAW_TIMES_CONTACTED, + ret, Contacts.LR_TIMES_CONTACTED); ret.remove(Contacts.LR_LAST_TIME_CONTACTED); ret.remove(Contacts.LR_TIMES_CONTACTED); |