cocktail_library 0.1.3 → 0.1.4
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 +4 -4
- data/lib/cocktail_library/cli.rb +5 -1
- data/lib/cocktail_library/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e1f321433788b63f1a8bcf1c50c9a98accd79f01
|
4
|
+
data.tar.gz: 343469e35068dcf4b8cb11c37eed70a08011b30f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ad5cd3dab9efed6e4a9331bde30caa1edf323878f2a4679212d96c90672d04f81a591766e454d4678b0c8281694f959369e62af381b4f17b203df1539d2c87eb
|
7
|
+
data.tar.gz: 12866a68bac57ba401f6c76908e1685f90d6623a4989bb9a44a79c2ac1d8d6de415d9b9666027d6ed7c9d7daf8bcdca0637017a62b581bd3df45ac7ca10d3fc5
|
data/lib/cocktail_library/cli.rb
CHANGED
@@ -96,18 +96,22 @@ class CocktailLibrary::CLI
|
|
96
96
|
puts "Please enter the drink name, or enter exit if you'd like to leave:"
|
97
97
|
puts ""
|
98
98
|
|
99
|
+
@search_list = @drinks_list.map {|el| el.downcase}
|
100
|
+
|
99
101
|
drink_selection = gets.chomp.downcase
|
100
102
|
#escape if not interested
|
101
103
|
if drink_selection == "exit"
|
102
104
|
puts ""
|
103
105
|
puts "Sorry we couldn't find something you were interested in."
|
104
106
|
exit
|
107
|
+
|
105
108
|
#escape if invalid entry
|
106
|
-
elsif
|
109
|
+
elsif !@search_list.include?(drink_selection)
|
107
110
|
puts ""
|
108
111
|
puts "Hmm, not sure how to make that one... Sorry about that!"
|
109
112
|
puts ""
|
110
113
|
drink_directions
|
114
|
+
|
111
115
|
else
|
112
116
|
#take drink selection and push it into the API
|
113
117
|
drink = @cocktail_db.drink_components(drink_selection)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cocktail_library
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Lita Stephenson
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-09-
|
11
|
+
date: 2017-09-18 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|