|
@@ -194,8 +194,9 @@ Cards.mutations({
|
|
Cards.before.insert((userId, doc) => {
|
|
Cards.before.insert((userId, doc) => {
|
|
doc.createdAt = new Date();
|
|
doc.createdAt = new Date();
|
|
doc.dateLastActivity = new Date();
|
|
doc.dateLastActivity = new Date();
|
|
- doc.archived = false;
|
|
|
|
-
|
|
|
|
|
|
+ if(!doc.hasOwnProperty('archived')){
|
|
|
|
+ doc.archived = false;
|
|
|
|
+ }
|
|
if (!doc.userId) {
|
|
if (!doc.userId) {
|
|
doc.userId = userId;
|
|
doc.userId = userId;
|
|
}
|
|
}
|