mirror of
https://github.com/sudoxnym/habitica.git
synced 2026-07-18 01:42:20 +00:00
fix(valentine): what? cards aren't getting added to array first time,
only 2nd+. Maybe an issue with markModified?
This commit is contained in:
parent
608b829d7e
commit
a6b2191927
2 changed files with 2 additions and 2 deletions
2
dist/habitrpg-shared.js
vendored
2
dist/habitrpg-shared.js
vendored
|
|
@ -10542,7 +10542,7 @@ var global=typeof self !== "undefined" ? self : typeof window !== "undefined" ?
|
|||
});
|
||||
((_ref = (_base = target.items.special).valentineReceived) != null ? _ref : _base.valentineReceived = []).push(user.profile.name);
|
||||
if (typeof target.markModified === "function") {
|
||||
target.markModified('items.special.valentineReceived');
|
||||
target.markModified('items.special');
|
||||
}
|
||||
return user.stats.gp -= 10;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -479,7 +479,7 @@ api.spells =
|
|||
t.achievements.valentine ?= 0
|
||||
t.achievements.valentine++
|
||||
(target.items.special.valentineReceived ?= []).push user.profile.name
|
||||
target.markModified? 'items.special.valentineReceived'
|
||||
target.markModified? 'items.special'
|
||||
user.stats.gp -= 10
|
||||
|
||||
# Intercept all spells to reduce user.stats.mp after casting the spell
|
||||
|
|
|
|||
Loading…
Reference in a new issue