Buggy code:
public class Reddit extends MultiDexApplication implements Application . ActivityLifecycleCallbacks { public static final String EMPTY_STRING = "NOTHING" ; public static final long BACKGROUND_DELAY = 500 ; public static final long enter_animation_time_original = 600 ; public static final String PREF_LAYOUT = "PRESET" ; public static IabHelper mHelper ; public static SearchSort search = SearchSort . RELEVANCE ; public static long enter_animation_time = Reddit . enter_animation_time_original ; public static int enter_animation_time_multiplier = 1 ; public static String titleFiltersRegex ; public static String textFiltersRegex ; public static String domainFiltersRegex ; public static Authentication authentication ; public static Sorting defaultSorting ; public static CommentSort defaultCommentSorting ; public static TimePeriod timePeriod ; public static SharedPreferences colors ; public static SharedPreferences appRestart ; public static int dpWidth ; public static int notificationTime ; public static NotificationJobScheduler notifications ; public static SharedPreferences seen ; public static SharedPreferences hidden ; public static boolean isLoading = false ; public static long time = System . currentTimeMillis ( ) ; public static boolean fabClear ; public static ArrayList < Integer > lastposition ; public static int currentPosition ; public static int themeBack ; public static SharedPreferences cachedData ; private final List < Reddit . Listener > listeners = new ArrayList < > ( ) ; private final Handler mBackgroundDelayHandler = new Handler ( ) ; public boolean active ; public boolean mInBackground = true ; boolean firstStart = false ; boolean hasDone ; boolean hasDone2 ; private ImageLoader defaultImageLoader ; private boolean closed = false ; private Runnable mBackgroundTransition ; private boolean isRestarting ; public static void forceRestart ( Context context ) { } public static void forceRestart ( Context c , boolean forceLoadScreen ) { <START_BUG> Reddit . appRestart . edit ( ) . putString ( "startScreen" , "" ) . apply ( ) ; <END_BUG> Reddit . forceRestart ( c ) ; } public static void defaultShareText ( String url , Context c ) { } public static void defaultShare ( String url , Context c ) { } private static boolean isPackageInstalled ( final Context ctx ) { } public static String regex ( String toSplit ) { } public static String arrayToString ( ArrayList < String > array ) { } public static ArrayList < String > stringToArray ( String string ) { } public static Integer getSortingId ( ) { } public static Integer getSortingIdSearch ( ) { } public static Integer getTypeSearch ( ) { } public static String [ ] getSortingStrings ( Context c ) { } public static String [ ] getSearch ( Context c ) { } public static String [ ] getSortingStringsSearch ( Context c ) { } @ Override public void onLowMemory ( ) { } public ImageLoader getImageLoader ( ) { } public void registerListener ( Reddit . Listener listener ) { } public void unregisterListener ( Reddit . Listener listener ) { } public boolean isInBackground ( ) { } @ Override public void onActivityResumed ( Activity activity ) { } private void notifyOnBecameForeground ( ) { } @ Override public void onActivityPaused ( Activity activity ) { } private void notifyOnBecameBackground ( ) { } public static void setDefaultErrorHandler ( Context base ) { } @ Override public void onActivityStopped ( Activity activity ) { } @ Override public void onActivityCreated ( Activity activity , Bundle savedInstanceState ) { } @ Override public void onActivityStarted ( Activity activity ) { } @ Override public void onActivitySaveInstanceState ( Activity activity , Bundle outState ) { } @ Override public void onActivityDestroyed ( Activity activity ) { } @ Override public void onCreate ( ) { } public void doMainStuff ( ) { } public static void setSorting ( String s , Sorting sort ) { } public static HashMap < String , Sorting > sorting = new HashMap < > ( ) ; public static Sorting getSorting ( String subreddit ) { } public static void setTime ( String s , TimePeriod sort ) { } public static HashMap < String , TimePeriod > times = new HashMap < > ( ) ; public static TimePeriod getTime ( String subreddit ) { } public interface Listener { void onBecameForeground ( ) { } void onBecameBackground ( ) { } } private class SetupIAB extends AsyncTask < Void , Void , Void > { @ Override protected Void doInBackground ( Void ... params ) { } } }

Fix:
Reddit . appRestart . edit ( ) . putString ( "startScreen" , "" ) . commit ( ) ;