summaryrefslogtreecommitdiffstats
path: root/models/cardComments.js
diff options
context:
space:
mode:
Diffstat (limited to 'models/cardComments.js')
-rw-r--r--models/cardComments.js6
1 files changed, 6 insertions, 0 deletions
diff --git a/models/cardComments.js b/models/cardComments.js
index 974c5ec9..fcb97104 100644
--- a/models/cardComments.js
+++ b/models/cardComments.js
@@ -67,6 +67,12 @@ CardComments.allow({
});
CardComments.helpers({
+ copy(newCardId) {
+ this.cardId = newCardId;
+ delete this._id;
+ CardComments.insert(this);
+ },
+
user() {
return Users.findOne(this.userId);
},