ced_palindrome 0.1.0 → 0.2.0

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: b1891eb040b70994c370a71f9537b1396fbca089d6f77e4a0781aa0a9380f552
4
- data.tar.gz: e82bf013b56341825487bc23e4d4265bb0fb5bac3f8eb7ddf0948621d657aaa4
3
+ metadata.gz: fb8b2efc59f2eefb2688790ca938aafaf0da992188ddd6c842f9ada74e2a4bb8
4
+ data.tar.gz: f7a4108fdddd49cfca83a7ee2c4f9289b4bb3a4b5032a5db25642883846e301c
5
5
  SHA512:
6
- metadata.gz: 5048342156eac50c8b10fba3317d038e1622f84c46088c4fed6e312595bc4ca3c87796d3e9c16c8620e6f93c228a0f37d0fa781fc8621753efd6ea351102dd4f
7
- data.tar.gz: 4f616f1970765ebd7d8df2d2077242c7d7cb8bcb5c1793f3d9b31965b35567b248eda0355bd88665a241445f4ff8c25e7e1548f4be2b6f500d97101303f3a376
6
+ metadata.gz: 575d8d6d5487b9e611181f3e0a035a50d6ee7bf8c7584d0af6506f67c4a2f03e0e32f4e9e613744a192a29d74c164f74f0806d60fa1543196235c86cf22e732b
7
+ data.tar.gz: 4732689bf1b525a8c45795da5c676d8fd9a17dcbbe53faf3e9b6c23795ecd682327958dedba398a5df62c75e71361d5fd3f20370cce9862aa0bd4d4c4edb0b98
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- ced_palindrome (0.1.0)
4
+ ced_palindrome (0.2.0)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
data/README.md CHANGED
@@ -24,7 +24,7 @@ $ gem install ced_palindrome
24
24
 
25
25
  ## Usage
26
26
 
27
- `ded_palindrome` adds a `palindrome?` method to the `String` class, and can be used as follows:
27
+ `ced_palindrome` adds a `palindrome?` method to the `String` class, and can be used as follows:
28
28
 
29
29
  ```
30
30
  $ irb
@@ -42,4 +42,4 @@ $ irb
42
42
 
43
43
  ## License
44
44
 
45
- The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
45
+ The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module CedPalindrome
4
- VERSION = "0.1.0"
4
+ VERSION = "0.2.0"
5
5
  end
@@ -6,7 +6,11 @@ class String
6
6
 
7
7
  # Returns true for a palindrome, false otherwise.
8
8
  def palindrome?
9
- processed_content == processed_content.reverse
9
+ if processed_content.empty?
10
+ false
11
+ else
12
+ processed_content == processed_content.reverse
13
+ end
10
14
  end
11
15
 
12
16
  # Returns the letters in the string.
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ced_palindrome
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - ced-01
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2023-10-12 00:00:00.000000000 Z
11
+ date: 2023-10-26 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Lear Enough Ruby Palindrome detctor
14
14
  email: