diff --git a/actionpack/lib/action_dispatch/middleware/session/abstract_store.rb b/actionpack/lib/action_dispatch/middleware/session/abstract_store.rb
index <HASH>..<HASH> 100644
--- a/actionpack/lib/action_dispatch/middleware/session/abstract_store.rb
+++ b/actionpack/lib/action_dispatch/middleware/session/abstract_store.rb
@@ -165,7 +165,7 @@ module ActionDispatch
           return response unless value
 
           cookie = { :value => value }
-          unless options[:expire_after].nil?
+          if options[:expire_after]
             cookie[:expires] = Time.now + options.delete(:expire_after)
           end
no need to check for nil?