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

Commit f36da27b authored by Frank Preel's avatar Frank Preel
Browse files

Try to find if user is premium in several ways

parent 310186a8
Loading
Loading
Loading
Loading
+2 −4
Original line number Diff line number Diff line
@@ -915,12 +915,10 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
                "com.android.inputmethod.latin",
                Context.CONTEXT_INCLUDE_CODE | Context.CONTEXT_IGNORE_SECURITY
            );
            Log.d(TAG, "Contexte sécurisé créé avec succès: " + secureContext);
            Log.d(TAG, "Secur context: " + secureContext);
            return accountIsPremium(secureContext);
        } catch (PackageManager.NameNotFoundException e) {
            // Cas gravissime, impossible réellement en théorie dans ton cas précis
            Log.wtf(TAG, "Erreur CRITIQUE: Le package LatinIME n'est pas trouvé par createPackageContext()", e);
            // Logique de secours absolue: repli sur contexte initial même si restreint, mieux que rien
            Log.wtf(TAG, "Error createPackageContext()", e);
            return accountIsPremium(this);
        }
    }