Skip to content

Commit

Permalink
Rename config field
Browse files Browse the repository at this point in the history
Fix a checkstyle issue: the "config" parameter hid the class field.
  • Loading branch information
rom1v committed Nov 18, 2019
1 parent e87f7e6 commit 77ef7d9
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public class GnirehtetActivity extends Activity {

private static final int VPN_REQUEST_CODE = 0;

private VpnConfiguration config;
private VpnConfiguration requestedConfig;

@Override
protected void onCreate(Bundle savedInstanceState) {
Expand Down Expand Up @@ -81,17 +81,17 @@ private void stopGnirehtet() {
}

private void requestAuthorization(Intent vpnIntent, VpnConfiguration config) {
this.config = config;
this.requestedConfig = config;
startActivityForResult(vpnIntent, VPN_REQUEST_CODE);
}

@Override
protected void onActivityResult(int requestCode, int resultCode, Intent data) {
super.onActivityResult(requestCode, resultCode, data);
if (requestCode == VPN_REQUEST_CODE && resultCode == RESULT_OK) {
GnirehtetService.start(this, config);
GnirehtetService.start(this, requestedConfig);
}
config = null;
requestedConfig = null;
finish();
}
}

0 comments on commit 77ef7d9

Please sign in to comment.