client/posts: link to duplicates in upload form
This commit is contained in:
parent
5b565e3b00
commit
293b28117b
1 changed files with 4 additions and 0 deletions
|
@ -140,6 +140,10 @@ class Post extends events.EventTarget {
|
||||||
}
|
}
|
||||||
return Promise.resolve();
|
return Promise.resolve();
|
||||||
}, response => {
|
}, response => {
|
||||||
|
if (response.name === 'PostAlreadyUploadedError') {
|
||||||
|
return Promise.reject(
|
||||||
|
`Post already uploaded (@${response.otherPostId})`);
|
||||||
|
}
|
||||||
return Promise.reject(response.description);
|
return Promise.reject(response.description);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue