woody-decorators 4.2.0 → 4.3.0

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: 1fc09a74ca4f0feee5447dde1332e39d2d16a852
4
- data.tar.gz: d35a90590e2bbf6b110d564199e934dbeac3133a
3
+ metadata.gz: 6108426414e26796201d5ddb20bcfe7aa30c79f6
4
+ data.tar.gz: 4e070065bd712ec9d40fd26aab5071689d5cfcef
5
5
  SHA512:
6
- metadata.gz: 6533571e535ab88201ef18a34af152cd5432558ecfa988ead13eb2c579cbe760d3008314bd2d56600fa779fbe136a7e9833fb986920b1387060d59f7deeaae35
7
- data.tar.gz: 60f3a495ef16536c6e574f101131a959ba706ab57104e5c2376f0d6ea2b825590414b3b4f86963aeb1df33b56a9975295aa4ddfd37b495b99c67d6e95b41dcd5
6
+ metadata.gz: 9be12d26dac3fbd506cdd7a9703e37c8cd4afd5a69ccc5a5edc356bd70f873e302a5ee56f2ea77eb6a3be33dfceded22f4d3dd93b8118e4d96d34c5a1c0e7405
7
+ data.tar.gz: 84354771b339ffca91a993fbd4e782553576f827dc22539497d71e4850f6565777fc7c389b0d4efb07cf2a1b91e42f82490ea41b36b9804029cec1f921131a46
@@ -1,5 +1,5 @@
1
1
  module Woody
2
2
  module Decorators
3
- VERSION = '4.2.0'.freeze
3
+ VERSION = '4.3.0'.freeze
4
4
  end
5
5
  end
@@ -49,9 +49,11 @@ module Woody
49
49
  end
50
50
 
51
51
  def reward_total
52
- @model.rewards.inject(0) do |total, reward|
52
+ return 'SWAG 😎' if @model.rewards.empty?
53
+ t = @model.rewards.inject(0) do |total, reward|
53
54
  total + (reward.quantity * reward.amount)
54
55
  end
56
+ format('£%d', t)
55
57
  end
56
58
 
57
59
  def status
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: woody-decorators
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.2.0
4
+ version: 4.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - ''
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-06-30 00:00:00.000000000 Z
11
+ date: 2016-07-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler