bogo 0.1.6 → 0.1.8

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 5ef23bc2efa4e4bfcaf1de4a924eaa6e2ef4fd98
4
- data.tar.gz: b6db055fcf8ae478a604078c1bb3ff8dcb814b9e
3
+ metadata.gz: 4c5c90b42afcd5854ba741a6f0da9469a6d548bd
4
+ data.tar.gz: 1ae80d7c320ade21655bd0dd8b3f88b876341bb3
5
5
  SHA512:
6
- metadata.gz: 09b6a5b951c920aaf1e8ba050ba703f70ade67efb61839ef7666d81120bd24b51a4aca5ceca43281499ce34601ba83d6cc6fb6925e2dc66ae02d012dbb4a9e3b
7
- data.tar.gz: 80f99d175bc7a81233caaee8147adf367bb0985d3878bbda0e23094bafeb217849e4c97a134557e7a2c7a999015baa2c73da50a62db5dd5871db9d6b34b45635
6
+ metadata.gz: 8363d5481480cd9741d14407f8b67222085ac81a04d9844494b3729b0dc1d70d51e0c126484c76eb3bf57d6bc7868dd95e448bfd65a10d061670092dae6459ff
7
+ data.tar.gz: 36aac8260f6f7673ab7e37ac7aabb039dbf0037e97371d0b1af7ec31e5e878b53dae610d2005795db20c6b66e40b360c9f4f904a942d99e746193be699cf794c
data/CHANGELOG.md CHANGED
@@ -1,3 +1,7 @@
1
+ ## v0.1.8
2
+ * Use `#to_smash` to for duping to preserve types
3
+ * Force type on merges
4
+
1
5
  ## v0.1.6
2
6
  * Add utility module for easy direct access to helpers
3
7
  * Add support for automatic key conversion (:snake or :camel) on `Smash#to_smash`
data/lib/bogo/lazy.rb CHANGED
@@ -227,11 +227,7 @@ module Bogo
227
227
  class << self
228
228
 
229
229
  def inherited(klass)
230
- klass.set_attributes(
231
- MultiJson.load(
232
- MultiJson.dump(self.attributes)
233
- ).to_smash
234
- )
230
+ klass.set_attributes(self.attributes.to_smash)
235
231
  end
236
232
 
237
233
  end
@@ -76,7 +76,7 @@ module Bogo
76
76
  #
77
77
  # @param key [String, Symbol] identifier for data
78
78
  # @param direct [Truthy, Falsey] direct skips key prepend of object id
79
- # @return [NilClass]
79
+ # @return [Object] removed instance
80
80
  def unmemoize(key, direct=false)
81
81
  unless(direct)
82
82
  key = "#{self.object_id}_#{key}"
data/lib/bogo/smash.rb CHANGED
@@ -32,6 +32,11 @@ module Bogo
32
32
  super(hash)
33
33
  end
34
34
 
35
+ def merge(hash)
36
+ hash = hash.to_smash
37
+ super(hash)
38
+ end
39
+
35
40
  # Get value at given path
36
41
  #
37
42
  # @param args [String, Symbol] key path to walk
data/lib/bogo/version.rb CHANGED
@@ -1,4 +1,4 @@
1
1
  module Bogo
2
2
  # Current library version
3
- VERSION = Gem::Version.new('0.1.6')
3
+ VERSION = Gem::Version.new('0.1.8')
4
4
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bogo
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.6
4
+ version: 0.1.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Chris Roberts
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-01-30 00:00:00.000000000 Z
11
+ date: 2015-02-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: hashie