apmex-price 1.0.1 → 1.0.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/apmex-price.rb +1 -1
  3. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: d841b71690b8749604d6ad0bbc12e57d4b177fcf
4
- data.tar.gz: 65f180c3dd18188395709199c31fdfaf2918199c
3
+ metadata.gz: 7c8032ea5cd91c860caa51e0f030d2bd3138f788
4
+ data.tar.gz: 0a947756d74e7a1573664c00d3a02d3141ad37c5
5
5
  SHA512:
6
- metadata.gz: e3a5e49840437aa52c4df33cd7d7ca1ded95b3dd22d94a996bb186d9d7dc8c0a54d934968e9f2963f11f5c6396ab1fe475fe7f7bbaa8514f5f5d211eed6bf78f
7
- data.tar.gz: 872895cf98bd94dc118f6ab6f22920d3f95630ba6d78e7f7a4ce2dda679a53e9511aac176ad92dbab52cefa431206d9207d0b2b39ae59581c4242b144e5815d9
6
+ metadata.gz: 4c583ed446103bae71ebaf41020bfbcc430f1390de15ae7afc5978abcddd10c7df7ee556003f61a2af4750a70780d5e0f7fb68d4b5c63ab0cdb8de9651bdcac4
7
+ data.tar.gz: 8201b7ca5d7dcab8d7b61536e33a7acf4ad41b9c68d5340a2473a7e10eaf9bf3ad0c4a789941f00caea0589ed1c52337f3e7ca6e7ad5f1bc1c51f93cda09decd
@@ -41,7 +41,7 @@ class ApmexPrice
41
41
  def calculate
42
42
  @ounces_spot = (@spot * @ounces).round(2)
43
43
 
44
- if @buy != 0.0
44
+ if @buy > @ounces_spot
45
45
  @value = @buy
46
46
  else
47
47
  @value = @ounces_spot
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: apmex-price
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.1
4
+ version: 1.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - cscribn
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-12-07 00:00:00.000000000 Z
11
+ date: 2015-12-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: minitest