pinkman 1.2.0 → 1.2.1

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
  SHA256:
3
- metadata.gz: f86938283023ea352bf26a15f24d6fab77bfec2a92cec7ad839ec338b3eb4e4e
4
- data.tar.gz: 66bdc74ad7b9e3e15f02549bcd63ef280c73d884017a47d06e44d0c6bdd3a77d
3
+ metadata.gz: 6aa8b4899545b9b5316b066ff707731348e1afebc1c4f806a5bf81d17260d675
4
+ data.tar.gz: b469cb1c5872acda2b38925e97b98da806d7acf1fa5bc3713e65724e9c1ab166
5
5
  SHA512:
6
- metadata.gz: 9ce750515695c361e2c306a1466e2105e21f9f26de207f83a93b03fa405ab9a90fef47d4aed2b7de8bb1054838626738091da7e86c555888cc873a4953110595
7
- data.tar.gz: 1a00bb98b28bc45eb77eee2dded5af6308e9afc65f1558af9d81ff44f035072af09eb18574df9ae11023fa068f59731e1ad6ac3b8793d3d654dc2443f6f06442
6
+ metadata.gz: 98075c0520ec27d181d79377ae07a1b9012763e1d2da66a6dd6959418662826c848f240d8f7fd399b5779f1846825562d8d41cf934da2f363817e57dabe90d35
7
+ data.tar.gz: 2f5b700c2ea2d167c156ae560f717c2dae7e47f45f0c39b1f5a0ca5d043393f4da24a2225e1ffb458fe86b22f2e51c979453d482ae703e2eead864bdc8e6191d
@@ -45,12 +45,13 @@ class window.PinkmanObject extends window.PinkmanCommon
45
45
 
46
46
  # Desc: returns a javascript object version of this
47
47
  # Usage: a.attributes() #-> {key: value, key: value, ...}
48
- attributes: ->
48
+ attributes: (initialObj)->
49
49
  a = new Object
50
50
  for k,v of this
51
51
  if PinkmanObject.privateAttributes.indexOf(k) == -1 and typeof v != 'function'
52
52
  if (v? and typeof v == 'object' and v.isPink)
53
- a[k] = v.attributes()
53
+ # initial obj with unless condition stops circular reference
54
+ a[k] = v.attributes(this) unless (initialObj? and initialObj.pinkey == v.pinkey)
54
55
  else
55
56
  a[k] = v
56
57
  return a
@@ -1,3 +1,3 @@
1
1
  module Pinkman
2
- VERSION = "1.2.0"
2
+ VERSION = "1.2.1"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pinkman
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.0
4
+ version: 1.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Agilso Oliveira
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-03-29 00:00:00.000000000 Z
11
+ date: 2019-04-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler