mirror of
https://github.com/sudoxnym/habitica.git
synced 2026-07-19 18:24:12 +00:00
Correct ownsItem function to allow owning item if user has ever previously owned the item.
This commit is contained in:
parent
3000517b06
commit
03c1a957f6
1 changed files with 3 additions and 1 deletions
|
|
@ -1,5 +1,7 @@
|
|||
import { isBoolean } from 'lodash';
|
||||
|
||||
export function ownsItem (item) {
|
||||
return (user) => {
|
||||
return item && user.items.gear.owned[item];
|
||||
return item && isBoolean(user.items.gear.owned[item]);
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue