diff options
author | Joey Hess <joeyh@joeyh.name> | 2016-04-14 13:07:46 -0400 |
---|---|---|
committer | Joey Hess <joeyh@joeyh.name> | 2016-04-14 13:07:46 -0400 |
commit | 1835f915174e9fdf5aa73372efa80e4330b528f2 (patch) | |
tree | df3921a3a857b18d976512b556de5360be686df2 /Database/Keys.hs | |
parent | 648b41ab69475e1973651a35c64b4eadf7a97ec7 (diff) |
fix bug in unlocked file scanner that skipped over executable unlocked files
Diffstat (limited to 'Database/Keys.hs')
-rw-r--r-- | Database/Keys.hs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Database/Keys.hs b/Database/Keys.hs index 246ccd191..ed3878161 100644 --- a/Database/Keys.hs +++ b/Database/Keys.hs @@ -170,7 +170,10 @@ scanAssociatedFiles = whenM (isJust <$> inRepo Git.Branch.current) $ dropallassociated h = liftIO $ flip SQL.queueDb h $ delete $ from $ \(_r :: SqlExpr (Entity SQL.Associated)) -> return () - isregfile i = Git.Types.toBlobType (Git.LsTree.mode i) == Just Git.Types.FileBlob + isregfile i = case Git.Types.toBlobType (Git.LsTree.mode i) of + Just Git.Types.FileBlob -> True + Just Git.Types.ExecutableBlob -> True + _ -> False add h i k = liftIO $ flip SQL.queueDb h $ void $ insertUnique $ SQL.Associated (toIKey k) |