cache_store_redis 0.3.1 → 0.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/cache_store_redis/version.rb +1 -1
- data/lib/cache_store_redis.rb +5 -4
- metadata +1 -1
    
        checksums.yaml
    CHANGED
    
    | @@ -1,7 +1,7 @@ | |
| 1 1 | 
             
            ---
         | 
| 2 2 | 
             
            SHA1:
         | 
| 3 | 
            -
              metadata.gz:  | 
| 4 | 
            -
              data.tar.gz:  | 
| 3 | 
            +
              metadata.gz: f084e13e3602325ec84cb76fe89d5598813e0a53
         | 
| 4 | 
            +
              data.tar.gz: e70ac165ec4185dcbdbe197ac6bd891dd1d0de4c
         | 
| 5 5 | 
             
            SHA512:
         | 
| 6 | 
            -
              metadata.gz:  | 
| 7 | 
            -
              data.tar.gz:  | 
| 6 | 
            +
              metadata.gz: eda1b6abe1ca2bd749b2a20706107b69fba9b0e74d31269bb80ac07e5af129599fa9cb6d925a514ef90147856026a6a83435a94ee200eff3786b280856ada891
         | 
| 7 | 
            +
              data.tar.gz: ffb71b410f449b18af67372f203fe02c55e1b8b5cab2e53fbab1f2174c10c2d29505cee9f34bdfdb22041199c5bcb9fcffd6d237172ecfc86169267d31d90af1
         | 
    
        data/lib/cache_store_redis.rb
    CHANGED
    
    | @@ -7,6 +7,7 @@ require 'securerandom' | |
| 7 7 | 
             
            class RedisCacheStore
         | 
| 8 8 |  | 
| 9 9 | 
             
              def initialize(namespace = nil, config = nil)
         | 
| 10 | 
            +
             | 
| 10 11 | 
             
                if RUBY_PLATFORM != 'java'
         | 
| 11 12 | 
             
                  require 'oj'
         | 
| 12 13 | 
             
                end
         | 
| @@ -109,17 +110,17 @@ class RedisCacheStore | |
| 109 110 |  | 
| 110 111 | 
             
              def serialize(object)
         | 
| 111 112 | 
             
                if RUBY_PLATFORM == 'java'
         | 
| 112 | 
            -
                  Marshal::dump( | 
| 113 | 
            +
                  Marshal::dump(object)
         | 
| 113 114 | 
             
                else
         | 
| 114 | 
            -
                   | 
| 115 | 
            +
                  Oj.dump(object)
         | 
| 115 116 | 
             
                end
         | 
| 116 117 | 
             
              end
         | 
| 117 118 |  | 
| 118 119 | 
             
              def deserialize(object)
         | 
| 119 120 | 
             
                if RUBY_PLATFORM == 'java'
         | 
| 120 | 
            -
                  Marshal::load( | 
| 121 | 
            +
                  Marshal::load(object)
         | 
| 121 122 | 
             
                else
         | 
| 122 | 
            -
                   | 
| 123 | 
            +
                  Oj.load(object)
         | 
| 123 124 | 
             
                end
         | 
| 124 125 | 
             
              end
         | 
| 125 126 |  |