Skip to content

Commit

Permalink
fix: possible npe when rerunning tests
Browse files Browse the repository at this point in the history
  • Loading branch information
aanorbel committed Jul 19, 2024
1 parent 1598bd9 commit df4873a
Showing 1 changed file with 9 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -289,16 +289,21 @@ void explorerClick() {

@Override
public void onConfirmation(Serializable extra, int buttonClicked) {
if (buttonClicked == DialogInterface.BUTTON_POSITIVE && extra.equals(RERUN_KEY))
if (buttonClicked == DialogInterface.BUTTON_POSITIVE && extra.equals(RERUN_KEY)) {
AbstractSuite testSuite = getTestSuite.getForWebConnectivityReRunFrom(measurement.result, Collections.singletonList(measurement.url.url));
if (testSuite == null) {
return;
}
RunningActivity.runAsForegroundService(
this,
getTestSuite.getForWebConnectivityReRunFrom(measurement.result, Collections.singletonList(measurement.url.url)).asArray(),
testSuite.asArray(),
this::finish,
preferenceManager);
else if (buttonClicked == DialogInterface.BUTTON_POSITIVE)
} else if (buttonClicked == DialogInterface.BUTTON_POSITIVE) {
runAsyncTask();
else if (buttonClicked == DialogInterface.BUTTON_NEUTRAL)
} else if (buttonClicked == DialogInterface.BUTTON_NEUTRAL) {
startActivity(TextActivity.newIntent(this, TextActivity.TYPE_UPLOAD_LOG, (String) extra));
}
}

public static class ResubmitAsyncTask extends ResubmitTask<MeasurementDetailActivity> {
Expand Down

0 comments on commit df4873a

Please sign in to comment.