enum_kit 0.3.0 → 0.3.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: e30bee3ea7d57c8fbaf1ac5ca571ee023eb3beb8721572c27192387007b72146
4
- data.tar.gz: 87646c8ab4a8945d937d65724bfa83df77e080b81d9242c67efb4f9bba87f861
3
+ metadata.gz: 46151b7e3c722bdc1167009a555fdad2185b388e052ab79435f42db13854efe9
4
+ data.tar.gz: 5ab21f12c01a51d2b4a8a73dd7b49309e3553605aa34353e2e80b6fa379ed334
5
5
  SHA512:
6
- metadata.gz: f3241b467c772bf71e2b9383babebc3de084578f8a95a7a96ccb84a44a1c00e2576c0b9d635b40f78b2327b7a879079068e6dc5146f8d6c2820880992dd105d6
7
- data.tar.gz: c0564d3bb4188e180366645e6527b30058d058012edbfab3d0f915272ec766e764318b7a52f9207691a53851e6d5523fec8fea3d5cc1dc6f3187e5774ed2b217
6
+ metadata.gz: 6dd953c03f3b9fcf604ad95b230bd4449e2047117aa7e5b735aaa2ff999a19254729a0b54aa3bb1c48a5f3c306dd2844bacd8589be486f356f460b5d646afc73
7
+ data.tar.gz: e40481b46c5f01d4185dfec50557b908bdd5e6abce649220d08a149bb970122c0c0a2fea791bef3a61d013b110ee910099ead0802a17361e069bd950f1bf2d76
@@ -44,13 +44,13 @@ module EnumKit
44
44
 
45
45
  # Invert the creation of an enum type by deleting it.
46
46
  #
47
- def invert_create_enum(args)
47
+ def invert_create_enum(*args)
48
48
  record(:drop_enum, args.first)
49
49
  end
50
50
 
51
51
  # Invert the renaming of an enum by renaming it back to the previous name.
52
52
  #
53
- def invert_rename_enum(args)
53
+ def invert_rename_enum(*args)
54
54
  record(:rename_enum, args.reverse)
55
55
  end
56
56
 
@@ -59,7 +59,7 @@ module EnumKit
59
59
  # Note that `drop_enum` can only be reversed if given a collection of values to call `create_enum` with as the
60
60
  # previously deleted enum values cannot be automatically determined.
61
61
  #
62
- def invert_drop_enum(args)
62
+ def invert_drop_enum(*args)
63
63
  unless args.length > 1
64
64
  raise ActiveRecord::IrreversibleMigration, 'drop_enum is only reversible if given an Array of values.'
65
65
  end
@@ -69,13 +69,13 @@ module EnumKit
69
69
 
70
70
  # Invert the addition of a value to an enum type by removing the value.
71
71
  #
72
- def invert_add_enum_value(_args)
72
+ def invert_add_enum_value(*args)
73
73
  raise ActiveRecord::IrreversibleMigration, 'add_enum_value is not reversible.'
74
74
  end
75
75
 
76
76
  # Invert the renaming of an enum's value by renaming it back to the previous value.
77
77
  #
78
- def invert_rename_enum_value(args)
78
+ def invert_rename_enum_value(*args)
79
79
  record(:rename_enum_value, args[0], args[2], args[1])
80
80
  end
81
81
  end
@@ -3,5 +3,5 @@
3
3
  module EnumKit
4
4
  # @return [String] The gem's semantic version number.
5
5
  #
6
- VERSION = '0.3.0'
6
+ VERSION = '0.3.1'
7
7
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: enum_kit
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nialto Services
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-12-06 00:00:00.000000000 Z
11
+ date: 2020-02-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activerecord
@@ -235,7 +235,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
235
235
  - !ruby/object:Gem::Version
236
236
  version: '0'
237
237
  requirements: []
238
- rubygems_version: 3.0.3
238
+ rubygems_version: 3.1.2
239
239
  signing_key:
240
240
  specification_version: 4
241
241
  summary: Native PostgreSQL enum support for Ruby on Rails.