mirror of
https://github.com/discourse/discourse.git
synced 2024-12-01 13:09:33 -06:00
DEV: Make uppy markdown resolvers async/await (#27117)
This commit is contained in:
parent
9d7f374c0f
commit
0d49571279
@ -319,13 +319,13 @@ export default Mixin.create(ExtendableUploader, UppyS3Multipart, {
|
||||
});
|
||||
|
||||
this._uppyInstance.on("upload-success", (file, response) => {
|
||||
run(() => {
|
||||
run(async () => {
|
||||
if (!this._uppyInstance) {
|
||||
return;
|
||||
}
|
||||
this._removeInProgressUpload(file.id);
|
||||
let upload = response.body;
|
||||
const markdown = this.uploadMarkdownResolvers.reduce(
|
||||
const markdown = await this.uploadMarkdownResolvers.reduce(
|
||||
(md, resolver) => resolver(upload) || md,
|
||||
getUploadMarkdown(upload)
|
||||
);
|
||||
|
Loading…
Reference in New Issue
Block a user