Files
Daniel Elliott c080f0d97f Add Discord community version (64-bit only)
- Added realracing3-community.apk (71.57 MB)
- Removed 32-bit support (armeabi-v7a)
- Only includes arm64-v8a libraries
- Decompiled source code included
- Added README-community.md with analysis
2026-02-18 15:48:36 -08:00

54 lines
2.0 KiB
Java

package com.facebook;
import android.content.SharedPreferences;
import kotlin.jvm.internal.DefaultConstructorMarker;
import kotlin.jvm.internal.Intrinsics;
import org.json.JSONException;
import org.json.JSONObject;
/* loaded from: classes2.dex */
public final class ProfileCache {
public static final String CACHED_PROFILE_KEY = "com.facebook.ProfileManager.CachedProfile";
public static final Companion Companion = new Companion(null);
public static final String SHARED_PREFERENCES_NAME = "com.facebook.AccessTokenManager.SharedPreferences";
private final SharedPreferences sharedPreferences;
public ProfileCache() {
SharedPreferences sharedPreferences = FacebookSdk.getApplicationContext().getSharedPreferences("com.facebook.AccessTokenManager.SharedPreferences", 0);
Intrinsics.checkNotNullExpressionValue(sharedPreferences, "FacebookSdk.getApplicationContext()\n .getSharedPreferences(SHARED_PREFERENCES_NAME, Context.MODE_PRIVATE)");
this.sharedPreferences = sharedPreferences;
}
public final Profile load() {
String string = this.sharedPreferences.getString(CACHED_PROFILE_KEY, null);
if (string != null) {
try {
return new Profile(new JSONObject(string));
} catch (JSONException unused) {
}
}
return null;
}
public final void save(Profile profile) {
Intrinsics.checkNotNullParameter(profile, "profile");
JSONObject jSONObject = profile.toJSONObject();
if (jSONObject != null) {
this.sharedPreferences.edit().putString(CACHED_PROFILE_KEY, jSONObject.toString()).apply();
}
}
public final void clear() {
this.sharedPreferences.edit().remove(CACHED_PROFILE_KEY).apply();
}
public static final class Companion {
public /* synthetic */ Companion(DefaultConstructorMarker defaultConstructorMarker) {
this();
}
private Companion() {
}
}
}