Skip to content

Commit

Permalink
Allow submitting a draft without creating a final comment
Browse files Browse the repository at this point in the history
  • Loading branch information
Rachel Macfarlane committed Dec 20, 2018
1 parent bb52164 commit 604cc76
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -429,7 +429,9 @@ export class ReviewZoneWidget extends ZoneWidget {
submitdraftButton.onDidClick(async () => {
try {
let lineNumber = this._commentGlyph.getPosition().position.lineNumber;
await this.createComment(lineNumber);
if (this._commentEditor.getValue()) {
await this.createComment(lineNumber);
}
await this.commentService.finishDraft(this._owner, this.editor.getModel().uri);
} catch (e) {
this.handleError(e);
Expand Down

0 comments on commit 604cc76

Please sign in to comment.