mirror of
https://github.com/sudoxnym/habitica-self-host.git
synced 2026-07-31 19:20:25 +00:00
possible fix for #562 - reflists sometimes contain a null value
This commit is contained in:
parent
bb5fe4520f
commit
8c1c5bba13
1 changed files with 1 additions and 1 deletions
|
|
@ -175,7 +175,7 @@ module.exports.updateUser = (model) ->
|
|||
union = _.union obj[type + 'Ids'], taskIds
|
||||
|
||||
# 2. remove empty (grey) tasks
|
||||
preened = _.filter(union, (val) -> _.contains(taskIds, val))
|
||||
preened = _.filter union, (val) -> _.contains(taskIds, val) and val?
|
||||
|
||||
# There were indeed issues found, set the new list
|
||||
batch.set("#{type}Ids", preened) # if _.difference(preened, userObj[path]).length != 0
|
||||
|
|
|
|||
Loading…
Reference in a new issue