diff --git a/persistent-ratelimit.cabal b/persistent-ratelimit.cabal
--- a/persistent-ratelimit.cabal
+++ b/persistent-ratelimit.cabal
@@ -10,7 +10,7 @@
 -- PVP summary:      +-+------- breaking API changes
 --                   | | +----- non-breaking API additions
 --                   | | | +--- code changes with no API change
-version:             0.1.0.0
+version:             0.1.0.1
 
 -- A short (one-line) description of the package.
 synopsis:            A library for rate limiting activities with a persistent backend. 
@@ -64,6 +64,9 @@
   
   -- Directories containing source files.
   hs-source-dirs:      src
+
+  ghc-options:   -Wall -fwarn-tabs -fno-warn-orphans -fno-warn-type-defaults -fno-warn-name-shadowing
+  -- -Werror 
   
   -- Base language which the package is written in.
   default-language:    Haskell2010
diff --git a/src/Database/Persist/RateLimit.hs b/src/Database/Persist/RateLimit.hs
--- a/src/Database/Persist/RateLimit.hs
+++ b/src/Database/Persist/RateLimit.hs
@@ -16,13 +16,13 @@
     timeConstructor :: action -> EntityField entity UTCTime
 
     -- | Filter to delete the records of a specific action. 
+    -- The default is `[]`. 
+    -- You probably only need this if multiple rate limiters use the same database entity. 
     deleteFilters :: action -> [Filter entity]
+    deleteFilters _ = []
 
-    -- | Optionally add additional filters for database queries. 
-    -- The default is `[]`. 
-    -- You probably only need this if multiple rate limiters use the same entity. 
+    -- | Filters to specify an action for database queries. 
     rateLimitFilters :: action -> [Filter entity]
-    rateLimitFilters _ = []
 
 -- | Returns the number of actions remaining for the current period. 
 numberOfRemainingActions :: (RateLimit action entity, 
@@ -48,7 +48,7 @@
         PersistQuery (YesodPersistBackend site)) => 
     action -> HandlerT site IO Bool
 canPerformAction action = 
-    numberOfRemainingActions action >>= return . (> 0)
+    fmap (> 0) $ numberOfRemainingActions action
 
 -- | Record when an action occurs. 
 recordAction :: (RateLimit action entity,
@@ -70,7 +70,7 @@
         PersistQuery (YesodPersistBackend site)) => 
     action -> HandlerT site IO ()
 deleteRecordedAction action =
-    let filters = deleteFilters action in
+    let filters = rateLimitFilters action in
     runDB $ deleteWhere filters
 
 -- | Periodically call this function to delete old actions that are past the rate limit period. 
@@ -84,7 +84,7 @@
 cleanOldActions action = do
     let ( _, period) = rateLimit action
     let timeConstr = timeConstructor action
-    let filters = rateLimitFilters action
+    let filters = deleteFilters action
     now <- lift getCurrentTime
     let timeBound = addUTCTime (fromIntegral $ negate period) now
-    runDB $ deleteWhere filters
+    runDB $ deleteWhere $ (timeConstr <. timeBound):filters
