money 6.14.0 → 6.14.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: 8e355db8bf8840c00422e9dd38b20dd86f0e8b64d495f4070d4ca1871cb83a6b
4
- data.tar.gz: 2ad4f5c341ef5302ed3a7d14f094ad941a64c12473a6bf8b0f796dd096734130
3
+ metadata.gz: 766ce2bf89d38cdc9280a79a77e1e6ccf940d1453a6b3d507e1a9ea81fd1d8ca
4
+ data.tar.gz: 9fb7990b6742cc6778733f3369a129e8911ac85f6c796f94f3e120af2e7c9794
5
5
  SHA512:
6
- metadata.gz: 83ad5d10e2480f8f47ad8c92a2db23c7da1a69b587e194e25ffd4d024bf124c4abced87478b1b18c1542b50df7a3daa0d44d834f1e89cfb7e6e7d233c77675f3
7
- data.tar.gz: 5ffa2bd650dad694b048d0b648a3059750b24b60712e93224967f0b2814c0451eed8b6b3f252ccf621ca1b92d61ad1157131238a2dfa5cfa3f9b33baa05162c4
6
+ metadata.gz: 3c6f467ccdfac45d2603a7642cf0da25cf0a4057bfa4d03c33a20acb4805b120b8fbe4c9b9cb8bdea6a3cc89d92425c5da19aaf5eef07827e5b16f82d054db13
7
+ data.tar.gz: 749fc675428631b124ec50da09f76f253c7b76cb350262f82dc53de5f334e30bd4d143c1477ab76305ad747c29fb7750ca91976f5f2562d212580cf65158dde7
data/CHANGELOG.md CHANGED
@@ -1,6 +1,19 @@
1
1
  # Changelog
2
2
 
3
- ## 6.13.9
3
+ ## 6.14.1
4
+
5
+ - Fix CHF format regression introduced in v6.14.0
6
+ - Fix deprecation warning in #format_decimal_part
7
+
8
+ ## 6.14.0
9
+
10
+ - Fix Bahraini dinar symbol
11
+ - Raise exception when default currency is not set or passed as parameter
12
+ - Allow specifying default_bank as a lambda
13
+ - Allow passing a default format in currencies definition only valid without symbol_position
14
+ - Always allow comparison with zero Money
15
+ - Rename Money.infinite_precision to default_infinite_precision
16
+ - Add Currency.reset! method to reload all the default currency definitions
4
17
  - Fix edgecase for Money#allocate when applying to array of all zero values
5
18
 
6
19
  ## 6.13.8
data/README.md CHANGED
@@ -411,7 +411,7 @@ Money.from_amount(2.34567).format #=> "$2.35"
411
411
  To retain the additional precision, you will also need to set `infinite_precision` to `true`.
412
412
 
413
413
  ```ruby
414
- Money.infinite_precision = true
414
+ Money.default_infinite_precision = true
415
415
  Money.from_amount(2.34567).format #=> "$2.34567"
416
416
  ```
417
417
 
@@ -423,7 +423,7 @@ To round to the nearest cent (or anything more precise), you can use the `round`
423
423
  2.34567.round(2) #=> 2.35
424
424
 
425
425
  # Money
426
- Money.infinite_precision = true
426
+ Money.default_infinite_precision = true
427
427
  Money.new(2.34567).format #=> "$0.0234567"
428
428
  Money.new(2.34567).round.format #=> "$0.02"
429
429
  Money.new(2.34567).round(BigDecimal::ROUND_HALF_UP, 2).format #=> "$0.0235"
@@ -452,7 +452,7 @@
452
452
  "subunit": "Rappen",
453
453
  "subunit_to_unit": 100,
454
454
  "symbol_first": true,
455
- "format": "%u %n",
455
+ "format": "%u%n",
456
456
  "html_entity": "",
457
457
  "decimal_mark": ".",
458
458
  "thousands_separator": ",",
@@ -347,7 +347,7 @@ class Money
347
347
  end
348
348
 
349
349
  def format_decimal_part(value)
350
- return nil if currency.decimal_places == 0 && !Money.infinite_precision
350
+ return nil if currency.decimal_places == 0 && !Money.default_infinite_precision
351
351
  return nil if rules[:no_cents]
352
352
  return nil if rules[:no_cents_if_whole] && value.to_i == 0
353
353
 
data/lib/money/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  class Money
2
- VERSION = '6.14.0'
2
+ VERSION = '6.14.1'
3
3
  end
metadata CHANGED
@@ -1,15 +1,15 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: money
3
3
  version: !ruby/object:Gem::Version
4
- version: 6.14.0
4
+ version: 6.14.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Shane Emmons
8
8
  - Anthony Dmitriyev
9
- autorequire:
9
+ autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2021-01-17 00:00:00.000000000 Z
12
+ date: 2021-02-25 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: i18n
@@ -144,7 +144,7 @@ metadata:
144
144
  changelog_uri: https://github.com/RubyMoney/money/blob/master/CHANGELOG.md
145
145
  source_code_uri: https://github.com/RubyMoney/money/
146
146
  bug_tracker_uri: https://github.com/RubyMoney/money/issues
147
- post_install_message:
147
+ post_install_message:
148
148
  rdoc_options: []
149
149
  require_paths:
150
150
  - lib
@@ -159,8 +159,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
159
159
  - !ruby/object:Gem::Version
160
160
  version: '0'
161
161
  requirements: []
162
- rubygems_version: 3.0.3
163
- signing_key:
162
+ rubygems_version: 3.1.2
163
+ signing_key:
164
164
  specification_version: 4
165
165
  summary: A Ruby Library for dealing with money and currency conversion.
166
166
  test_files: []