miracle_grow 0.1.6 → 0.1.7

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: d4e8f27f1790204a02248bd9ceed3f1af2051be4
4
- data.tar.gz: 051eb30927a0957dba190f26118240fd3a16ddb8
3
+ metadata.gz: 0ccca65589cf6781ecc8b8757b19696e715fd9b6
4
+ data.tar.gz: d09ecf587028b3ff7539c41a4642c8d28265ae1a
5
5
  SHA512:
6
- metadata.gz: 23f07b455c4cf09cb9eed7954e5bdd985a894dd6234d9fe5852f30749ef80764bfd45e31363ab027be73e8c95d7297df11a3982f8c59f4dc89db4da95b1f8446
7
- data.tar.gz: 5e62ec72abb3e825dd0a956095ef71dd9a443f1efb15e588e7dc2c5b864df91accb479460a2f07b6e0af13baaae9bf9a2670dbf80e53d467fbcd0aea16ba8f5a
6
+ metadata.gz: 8464e40f68a3897f2ea9570b278aec46a3ed1291e72c6d9270f08253f14cd228c8c4180bd5f9637455c8cfce7d9766b79dcf9dd16e6473301557b3a8a77b8a8e
7
+ data.tar.gz: cfeff142f17de2b99ce29e3dcc9676de05aab130aa08c8bf7b01ed4f38105800f4ee52940e7109ea3f18313ef24a6c68d8f86effb697798149060437d0c00682
@@ -3,36 +3,36 @@ module MiracleGrow
3
3
  class Bed
4
4
  class << self
5
5
  def find_bed(id)
6
- response = Faraday.get("#{env["SERVER_NAME"]}/api/v1/beds/#{id}")
6
+ response = Faraday.get("#{ENV["HOST"]}/api/v1/beds/#{id}")
7
7
  JSON.parse(response.body)
8
8
  end
9
9
 
10
10
  def create_bed(params)
11
- Faraday.post("#{env["SERVER_NAME"]}/api/v1/beds") do |req|
11
+ Faraday.post("#{ENV["HOST"]}/api/v1/beds") do |req|
12
12
  request = params
13
13
  req.body = params
14
14
  end
15
15
  end
16
16
 
17
17
  def patch_bed(params)
18
- Faraday.put("#{env["SERVER_NAME"]}/api/v1/beds/#{(params[:id])}") do |req|
18
+ Faraday.put("#{ENV["HOST"]}/api/v1/beds/#{(params[:id])}") do |req|
19
19
  request = params
20
20
  req.body = params
21
21
  end
22
22
  end
23
23
 
24
24
  def current_users_beds(uid)
25
- response = Faraday.get("#{env["SERVER_NAME"]}/api/v1/beds/for_user/#{uid}")
25
+ response = Faraday.get("#{ENV["HOST"]}/api/v1/beds/for_user/#{uid}")
26
26
  JSON.parse(response.body)
27
27
  end
28
28
 
29
29
  def default_bed(uid)
30
- response = Faraday.get("#{env["SERVER_NAME"]}/api/v1/beds/default_for_user/#{uid}")
30
+ response = Faraday.get("#{ENV["HOST"]}/api/v1/beds/default_for_user/#{uid}")
31
31
  JSON.parse(response.body)
32
32
  end
33
33
 
34
34
  def show_bed(id)
35
- response = Faraday.get("#{env["SERVER_NAME"]}/api/v1/beds/#{id}")
35
+ response = Faraday.get("#{ENV["HOST"]}/api/v1/beds/#{id}")
36
36
  JSON.parse(response.body)
37
37
  end
38
38
 
@@ -4,7 +4,7 @@ module MiracleGrow
4
4
  class << self
5
5
 
6
6
  def all_the_plants
7
- response = Faraday.get("#{env["SERVER_NAME"]}/api/v1/plants")
7
+ response = Faraday.get("#{ENV["HOST"]}/api/v1/plants")
8
8
  JSON.parse(response.body)
9
9
  end
10
10
 
@@ -1,3 +1,3 @@
1
1
  module MiracleGrow
2
- VERSION = "0.1.6"
2
+ VERSION = "0.1.7"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: miracle_grow
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.6
4
+ version: 0.1.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ben Lewinsky