We got nominated! Help us out and vote for GitHub as Best Bootstrapped Startup of 2008. (You can vote once a day.) [ hide ]

public
Description: ActiveSupport::Cache wrapper for libmemcached
Clone URL: git://github.com/37signals/libmemcached_store.git
Fix a subtle bug that would cause values never to be marshalled
packagethief (author)
Sat Aug 23 15:53:28 -0700 2008
commit  e417fabeddca9028ffd5f50df8fcef5178e0c5a6
tree    b623f7c21cd5e40e836de0a6712de82dd4e40caf
parent  4e907d77708e8382bb8a55197e596e53d63f5490
...
92
93
94
 
95
96
 
97
98
99
100
 
101
102
103
...
92
93
94
95
96
 
97
98
99
100
 
101
102
103
104
0
@@ -92,12 +92,13 @@ module ActiveSupport
0
       end
0
 
0
       private
0
+
0
         def expires_in(options)
0
- (options && options[:expires_in]) || 0
0
+ (options || {})[:expires_in] || 0
0
         end
0
 
0
         def marshal?(options)
0
- options && !options[:raw]
0
+ !(options || {})[:raw]
0
         end
0
 
0
         def log_error(exception)

Comments

  • Oh man! I thought I was going crazy when I did a fetch, write, then re-fetch and it spat back at me TypeError: incompatible marshal file format (can't be read)
    Turns out before the fix it was storing the #to_s value of the object.
    Sanity restored.