소스 검색

Add verys important return to ensure Promise chain works

rugk 7 년 전
부모
커밋
17131f3172
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      js/privatebin.js

+ 1 - 1
js/privatebin.js

@@ -3943,7 +3943,7 @@ jQuery.PrivateBin = (function($, sjcl, RawDeflate) {
 
             // TODO: change this callback to also use Promises instead,
             // this here just waits
-            Promise.all([encryptAttachmentPromise, encryptAttachmentNamePromise]).then(() => {
+            return Promise.all([encryptAttachmentPromise, encryptAttachmentNamePromise]).then(() => {
                 // run callback
                 return callback();
             });