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

Unverified Commit 0e3125d7 authored by Michael W's avatar Michael W Committed by Michael Bestas
Browse files

Dialer: Provide stub FilteredNumberProvider

* Something, somewhere, seems to cache the providers and makes dialer
  crash due to the missing one
* Provide one that does nothing

Change-Id: Idfd0afa696bcc75730abdf3667740b03a8b7191d
parent 139dc15f
Loading
Loading
Loading
Loading
+8 −1
Original line number Diff line number Diff line
@@ -15,6 +15,13 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
  package="com.android.dialer.blocking">

  <application />
  <application>
    <!-- Provide this since upgrade path seems to be messy; Only a stub class exists there -->
    <provider
        android:authorities="com.android.dialer.blocking.filterednumberprovider"
        android:exported="false"
        android:multiprocess="false"
        android:name="com.android.dialer.blocking.FilteredNumberProvider"/>
  </application>

</manifest>
+40 −0
Original line number Diff line number Diff line
/*
 * SPDX-FileCopyrightText: The LineageOS Project
 * SPDX-License-Identifier: Apache-2.0
 */
package com.android.dialer.blocking;

import android.content.ContentProvider;
import android.content.ContentValues;
import android.database.Cursor;
import android.net.Uri;

/** Stub class for upgrade path */
public class FilteredNumberProvider extends ContentProvider {
    @Override
    public boolean onCreate() {
        return false;
    }
    @Override
    public Cursor query(Uri uri, String[] projection, String selection, String[] selectionArgs,
                        String sortOrder) {
        return null;
    }
    @Override
    public String getType(Uri uri) {
        return null;
    }
    @Override
    public Uri insert(Uri uri, ContentValues values) {
        return null;
    }

    @Override
    public int delete(Uri uri, String selection, String[] selectionArgs) {
        return 0;
    }
    @Override
    public int update(Uri uri, ContentValues values, String selection, String[] selectionArgs) {
        return 0;
    }
}