mirror of
https://github.com/wekan/wekan.git
synced 2025-04-22 04:57:07 -04:00
Fix minicard cover functionality
Otherwise, if `this.coverId` is undefined then `Attachments.findOne()` would return any attachment.
This commit is contained in:
parent
b7105d7b57
commit
66d35a1528
1 changed files with 1 additions and 0 deletions
|
@ -535,6 +535,7 @@ Cards.helpers({
|
|||
},
|
||||
|
||||
cover() {
|
||||
if (!this.coverId) return false;
|
||||
const cover = Attachments.findOne(this.coverId);
|
||||
// if we return a cover before it is fully stored, we will get errors when we try to display it
|
||||
// todo XXX we could return a default "upload pending" image in the meantime?
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue