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

Commit fb34a6a9 authored by Jernej Virag's avatar Jernej Virag Committed by Android (Google) Code Review
Browse files

Merge "Add getContentObservers call to FakeSettings" into main

parents 688353b0 f461bdd7
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -70,6 +70,14 @@ class FakeSettings : SecureSettings, SystemSettings, UserSettingsProxy {
        }
    }

    fun getContentObservers(uri: Uri, userHandle: Int): List<ContentObserver> {
        if (userHandle == UserHandle.USER_ALL) {
            return contentObserversAllUsers[uri.toString()] ?: listOf()
        } else {
            return contentObservers[SettingsKey(userHandle, uri.toString())] ?: listOf()
        }
    }

    override fun getContentResolver(): ContentResolver {
        throw UnsupportedOperationException("FakeSettings.getContentResolver is not implemented")
    }