base32-alphabets 1.1.0 → 1.1.1

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: 94a33c87036d36e7280aae81da210d4155b20b54
4
- data.tar.gz: 6b1c22db5cb74881d9948cc23269c67678f9946b
3
+ metadata.gz: aad6b4b08320d7b50f69cd88881277c0f32adcdc
4
+ data.tar.gz: 78ac1976300053f0ba0348c6a880f1765843897d
5
5
  SHA512:
6
- metadata.gz: 0c98cf85b86052006d7928c5c271f03d30a24e55f90eabd73302d712536088ad39101e6b4b9352ac09be447ee1bebdae91d520b8237b727c4799a1d5507eb16f
7
- data.tar.gz: 697155fa0c6bf2c12b04021959e224970f12200ef3baaa545d199126ff028e536a7a0c9b2e771532ec328ffbb92fd317ef8c3c6ec86bc30830096e3f484a7f87
6
+ metadata.gz: 20158649f45959d3cdf819445d4e3d028f6b343e82fabc2f21650442b5862619239f87893190d4efe5a1e7ae24f9a49dde9623ead391c734752d353a7b217005
7
+ data.tar.gz: acbe509305d8655b1c9cd8ae0dd71d5ef37bb896d87e0a67a526b7f6a410795693fda00329a8acfc2c1b91e43e868856d776c23f237f08f8e2e7ec38f8392365
@@ -26,8 +26,8 @@ def encode32( num_or_bytes )
26
26
  Base32.encode( num_or_bytes )
27
27
  end
28
28
 
29
- def decode32( str )
30
- Base32.decode( str )
29
+ def decode32( str_or_bytes )
30
+ Base32.decode( str_or_bytes )
31
31
  end
32
32
 
33
33
 
@@ -9,14 +9,15 @@ class Base
9
9
 
10
10
  def self.bytes( num_or_str )
11
11
  if num_or_str.is_a? String
12
- str = num_or_str
13
- num = decode( str )
12
+ str = num_or_str
13
+ bytes = _decode( str )
14
14
  else # assume number
15
- num = num_or_str
15
+ num = num_or_str
16
+ bytes = Base32._bytes( num )
16
17
  end
17
- Base32._bytes( num )
18
18
  end
19
19
 
20
+
20
21
  # Converts a base10 integer to a base32 string.
21
22
  def self.encode( num_or_bytes )
22
23
  if num_or_bytes.is_a? Array
@@ -5,7 +5,7 @@ module Base32
5
5
 
6
6
  MAJOR = 1
7
7
  MINOR = 1
8
- PATCH = 0
8
+ PATCH = 1
9
9
  VERSION = [MAJOR,MINOR,PATCH].join('.')
10
10
 
11
11
  def self.version
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: base32-alphabets
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.0
4
+ version: 1.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gerald Bauer