@@ -112,53 +112,49 @@ public boolean onCreateOptionsMenu(Menu menu) {
112112 @ Override
113113 protected void onCreate (Bundle savedInstanceState ) {
114114 super .onCreate (savedInstanceState );
115- try {
116- setContentView (R .layout .activity_main );
115+ setContentView (R .layout .activity_main );
117116
118- isSDCardAvailable ();
117+ isSDCardAvailable ();
119118
120- broadcastList = new ArrayList <>();
121- broadcastList .add (SynchronizeService .ACTION_CLAIM_COUNT_RESULT );
119+ broadcastList = new ArrayList <>();
120+ broadcastList .add (SynchronizeService .ACTION_CLAIM_COUNT_RESULT );
122121
123- progressDialog = new ProgressDialog (this );
124- progressDialog .setCancelable (false );
122+ progressDialog = new ProgressDialog (this );
123+ progressDialog .setCancelable (false );
125124
126- Toolbar toolbar = findViewById (R .id .toolbar );
127- setSupportActionBar (toolbar );
128- actionBar = getSupportActionBar ();
125+ Toolbar toolbar = findViewById (R .id .toolbar );
126+ setSupportActionBar (toolbar );
127+ actionBar = getSupportActionBar ();
129128
130- new Thread (this ::checkForUpdates ).start ();
129+ new Thread (this ::checkForUpdates ).start ();
131130
132- drawer = findViewById (R .id .drawer_layout );
133- ActionBarDrawerToggle toggle = new ActionBarDrawerToggle (
134- this , drawer , toolbar , R .string .navigation_drawer_open , R .string .navigation_drawer_close );
135- drawer .addDrawerListener (toggle );
136- toggle .syncState ();
131+ drawer = findViewById (R .id .drawer_layout );
132+ ActionBarDrawerToggle toggle = new ActionBarDrawerToggle (
133+ this , drawer , toolbar , R .string .navigation_drawer_open , R .string .navigation_drawer_close );
134+ drawer .addDrawerListener (toggle );
135+ toggle .syncState ();
137136
138- NavigationView navigationView = findViewById (R .id .nav_view );
139- navigationView .setNavigationItemSelectedListener (this ::onNavigationItemSelected );
137+ NavigationView navigationView = findViewById (R .id .nav_view );
138+ navigationView .setNavigationItemSelectedListener (this ::onNavigationItemSelected );
140139
141- View header = navigationView .getHeaderView (0 );
142- loginText = header .findViewById (R .id .LoginText );
143- loginText .setText (global .isLoggedIn () ? R .string .Logout : R .string .Login );
144- RelativeLayout loginButton = header .findViewById (R .id .LoginButton );
145- loginButton .setOnClickListener ((view ) -> changeLoginState ());
140+ View header = navigationView .getHeaderView (0 );
141+ loginText = header .findViewById (R .id .LoginText );
142+ loginText .setText (global .isLoggedIn () ? R .string .Logout : R .string .Login );
143+ RelativeLayout loginButton = header .findViewById (R .id .LoginButton );
144+ loginButton .setOnClickListener ((view ) -> changeLoginState ());
146145
147- accepted_count = findViewById (R .id .accepted_count );
148- rejected_count = findViewById (R .id .rejected_count );
149- entered_Count = findViewById (R .id .entered_count );
146+ accepted_count = findViewById (R .id .accepted_count );
147+ rejected_count = findViewById (R .id .rejected_count );
148+ entered_Count = findViewById (R .id .entered_count );
150149
151- accepted_count .setText ("0" );
152- rejected_count .setText ("0" );
153- entered_Count .setText ("0" );
150+ accepted_count .setText ("0" );
151+ rejected_count .setText ("0" );
152+ entered_Count .setText ("0" );
154153
155- AdminName = findViewById (R .id .AdminName );
154+ AdminName = findViewById (R .id .AdminName );
156155
157- if (checkRequirements ()) {
158- onAllRequirementsMet ();
159- }
160- } catch (Exception exception ) {
161- Sentry .captureException (exception );
156+ if (checkRequirements ()) {
157+ onAllRequirementsMet ();
162158 }
163159 }
164160
0 commit comments