Skip to content

Commit

Permalink
cancel the dialog when posting a reply
Browse files Browse the repository at this point in the history
  • Loading branch information
kidozh committed Jul 17, 2020
1 parent 3971ce9 commit f649329
Showing 1 changed file with 8 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1355,8 +1355,14 @@ public boolean onOptionsItemSelected(MenuItem item) {
}
if(checkIfThreadCanBePosted()){
// ensure whether user is agreed to publish
PostThreadConfirmDialogFragment fragment = new PostThreadConfirmDialogFragment(postThreadViewModel);
fragment.show(getSupportFragmentManager(),PostThreadConfirmDialogFragment.class.getSimpleName());
if(!isAPostReply()){
PostThreadConfirmDialogFragment fragment = new PostThreadConfirmDialogFragment(postThreadViewModel);
fragment.show(getSupportFragmentManager(),PostThreadConfirmDialogFragment.class.getSimpleName());
}
else {
new publishThreadTask().execute();
}


}
else {
Expand Down

0 comments on commit f649329

Please sign in to comment.