tonglian-ruby-sdk 0.3.2 → 0.3.3

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.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/tonglian-ruby-sdk.rb +4 -1
  3. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e1f015a90097c8606b7e562c0e36c9b11790a67e09dff8907588490ad5f51860
4
- data.tar.gz: 4fd341b8c531888fa2654c6fcc00fc48ab8cc69a7dce603debf4657b2c68d762
3
+ metadata.gz: 8aa46899e9a58b9458b26b4ebf9431e62edc486754e157d008b0c10874bddd28
4
+ data.tar.gz: 757473df369bf8acdc13393447ca605b83c89589bf05c23485e6a7fd0a7f6d49
5
5
  SHA512:
6
- metadata.gz: cce709c6a7e11e6663ec9ff1d0775ac6916b1e013715ebd3b2c333cd7bf57eed313e0b2b2b043101678a052459a58eef2332c6b7367dd354391eddaca54f52ef
7
- data.tar.gz: 62a3c6981b09430a152b408cb5e26a8f096f6f40eb182f6b47f93cd6d7809da2fc74470387cf828872fda6ed0bf0ae4d4e22974ee9f43d78c937c9d2cd92ab1c
6
+ metadata.gz: c7230b9b8cda0b5e263fc7741307c70ff3ad6b0c4f41a7065c0be3be3e0ec41f3e8a9c043b98cd0d3ebbcafef925c45347fb90525d898a2f0d0e62cd08503e33
7
+ data.tar.gz: 7fac9de10daa506113ad542890ed810af1d5d27bdf7ab482910da9ec3a4b2b253c97fbe9b2b45abdbbada7e9f774ae7218e341e61b4452558568950d7ed4c29d
@@ -125,8 +125,11 @@ module TonglianRubySdk
125
125
  result = {}
126
126
  obj.keys.sort.each { |k| result[k] = sort_object(obj[k]) }
127
127
  elsif obj.is_a? Array
128
+ # If obj is array, it doesn't need to sort.
129
+ # But still need to sort the items if they're hashes.
130
+ # And this process should recursively go to the bottom
128
131
  result = []
129
- obj.sort.each { |i| result.push(sort_object(i)) }
132
+ obj.each { |i| result.push(sort_object(i)) }
130
133
  else
131
134
  result = obj
132
135
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tonglian-ruby-sdk
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.2
4
+ version: 0.3.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Yi Zhang