mirror of
https://github.com/sudoxnym/habitica.git
synced 2026-05-19 04:08:54 +00:00
fix(backgrounds): disallow equipping unowned bashground
Also add missing headers when recording group task creation
This commit is contained in:
parent
5dc4fccddc
commit
ecac3f0c5f
2 changed files with 4 additions and 1 deletions
|
|
@ -68,6 +68,7 @@ api.createGroupTasks = {
|
|||
category: 'behavior',
|
||||
taskType: task.type,
|
||||
groupID: group._id,
|
||||
headers: req.headers,
|
||||
});
|
||||
});
|
||||
},
|
||||
|
|
|
|||
|
|
@ -97,7 +97,9 @@ function checkPreferencePurchase (user, path, item) {
|
|||
const itemPath = `${path}.${item}`;
|
||||
const appearance = _.get(common.content.appearances, itemPath);
|
||||
if (!appearance) return false;
|
||||
if (appearance.price === 0) return true;
|
||||
if (appearance.price === 0 && path !== 'background') {
|
||||
return true;
|
||||
}
|
||||
|
||||
return _.get(user.purchased, itemPath);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue