fix inverted logic in old associated files cleanup
This commit is contained in:
parent
722f56a99d
commit
b1a1b40a15
1 changed files with 1 additions and 1 deletions
|
@ -173,7 +173,7 @@ addAssociatedFile' k f = queueDb $ do
|
||||||
-- If the same file was associated with a different key before,
|
-- If the same file was associated with a different key before,
|
||||||
-- remove that.
|
-- remove that.
|
||||||
delete $ from $ \r -> do
|
delete $ from $ \r -> do
|
||||||
where_ (r ^. AssociatedFile ==. val (getTopFilePath f) &&. r ^. AssociatedKey ==. val sk)
|
where_ (r ^. AssociatedFile ==. val (getTopFilePath f) &&. not_ (r ^. AssociatedKey ==. val sk))
|
||||||
void $ insertUnique $ Associated sk (getTopFilePath f)
|
void $ insertUnique $ Associated sk (getTopFilePath f)
|
||||||
where
|
where
|
||||||
sk = toSKey k
|
sk = toSKey k
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue