switchman 1.5.8 → 1.5.9

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 6d7676d7b016d87da297714bb0ac6c4e6b2d2114
4
- data.tar.gz: 67746d37c000d95e9f59a8be237a3a602b8d2e89
3
+ metadata.gz: abf642d4e18ec28d2f9b71eb4aa3d4edb8ec8a92
4
+ data.tar.gz: 64297343a489ffdfc3eb22f851a2c11dc797d211
5
5
  SHA512:
6
- metadata.gz: 3dfceefb5d04a739ac608d547f502133d0f3fa0185b17092087c9b2b2526c2bf947f8aa1657448341302cf4ce706b1b95cbc8110f738e62d752a0be409ea6f30
7
- data.tar.gz: d1a2c684c4e720ed9e3e1777ac7c343ff83a9d8871e458b4644f8d1280ebec0bbfd52cd147d35ae9fec790599093623657209268efe43995e2ab01542e2bb12d
6
+ metadata.gz: b3c185968b0864ed798bda19dedb9268473f672e118ce01636f3d9c0449f902b7c3ae6a2244342530566232e42b38739df47f5af93ed00d3be60eb1c20906c7e
7
+ data.tar.gz: 3abd5123fa4d0807492131fd0179d17df0784b6c6abbca69fc178db9cd4fb78338037414ee0f3a44294d832933471010524e93c7a580361869eedeba535ff609
@@ -98,9 +98,11 @@ module Switchman
98
98
  def reverse_order!
99
99
  orders = order_values.uniq
100
100
  orders.reject!(&:blank?)
101
- orders = [arel_table[primary_key].desc] if orders.empty?
102
-
103
- self.order_values = reverse_sql_order(orders)
101
+ if orders.empty?
102
+ self.order_values = [arel_table[primary_key].desc]
103
+ else
104
+ self.order_values = reverse_sql_order(orders)
105
+ end
104
106
  self
105
107
  end
106
108
  end
@@ -1,3 +1,3 @@
1
1
  module Switchman
2
- VERSION = "1.5.8"
2
+ VERSION = "1.5.9"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: switchman
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.5.8
4
+ version: 1.5.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - Cody Cutrer