Convert BaseResource.save to return a promise.

Review Request #11642 — Created June 2, 2021 and submitted — Latest diff uploaded

Information

Review Board
master

Reviewers

This change updates the save machinery for various resources to use
promises and async/await instead of callbacks.

  • Ran js-tests.
  • Manually tested API token creation, comment editing, review request
    field editing, post-commit review request creation, ship-it revocation,
    and file attachment uploading.

Changes between revision 2 and 3

orig
1
2
3
4
5

Commits

Summary ID Author
Convert BaseResource.save to return a promise.
This change updates the save machinery for various resources to use promises and async/await instead of callbacks. Testing Done: - Ran js-tests. - Manually tested API token creation, comment editing, review request field editing, post-commit review request creation, ship-it revocation, and file attachment uploading.
fe570fdcdea6875baaf88600256a4b6b2511b21f David Trowbridge
Convert BaseResource.save to return a promise.
This change updates the save machinery for various resources to use promises and async/await instead of callbacks. Testing Done: - Ran js-tests. - Manually tested API token creation, comment editing, review request field editing, post-commit review request creation, ship-it revocation, and file attachment uploading.
2a68656268cbc391c8a76116055c98b34de93d28 David Trowbridge
reviewboard/static/rb/js/models/commentEditorModel.es6.js
reviewboard/static/rb/js/models/reviewRequestEditorModel.es6.js
reviewboard/static/rb/js/models/userSessionModel.es6.js
reviewboard/static/rb/js/models/tests/commentEditorModelTests.es6.js
reviewboard/static/rb/js/models/tests/reviewRequestEditorModelTests.es6.js
reviewboard/static/rb/js/newReviewRequest/views/postCommitView.es6.js
reviewboard/static/rb/js/newReviewRequest/views/tests/postCommitViewTests.es6.js
reviewboard/static/rb/js/resources/models/baseResourceModel.es6.js
reviewboard/static/rb/js/resources/models/draftReviewModel.es6.js
reviewboard/static/rb/js/resources/models/draftReviewRequestModel.es6.js
reviewboard/static/rb/js/resources/models/reviewGroupModel.es6.js
reviewboard/static/rb/js/resources/models/reviewReplyModel.es6.js
reviewboard/static/rb/js/resources/models/reviewRequestModel.es6.js
reviewboard/static/rb/js/resources/models/tests/baseResourceModelTests.es6.js
reviewboard/static/rb/js/resources/models/tests/draftReviewRequestModelTests.es6.js
reviewboard/static/rb/js/resources/models/tests/reviewGroupModelTests.es6.js
reviewboard/static/rb/js/ui/views/textEditorView.es6.js
reviewboard/static/rb/js/views/reviewDialogView.es6.js
reviewboard/static/rb/js/views/tests/reviewDialogViewTests.es6.js
reviewboard/static/rb/js/views/tests/reviewRequestEditorViewTests.es6.js
Loading...