grape-app 0.3.5 → 0.3.9

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: 6f036ccb754e375e8aab15cb8f33d7381571db80
4
- data.tar.gz: 72eab574e793cd7ca5d0361230b3874612d1072a
3
+ metadata.gz: 09744f62274a4af589f4e62e245ea9b654586eb2
4
+ data.tar.gz: 7721ff3f3ca675e89a6db3b02c841f2e6d3315e9
5
5
  SHA512:
6
- metadata.gz: a9291cf8eeb48134ffbbcf848bff1e2eec2ea24c4aede43fa4f2878cbcf827503e77d9d6b6d3ccf3c56ac5802ac462bebfff43271700734c7a4744c22abe179f
7
- data.tar.gz: a830649d991127605069a8f46ccf5c4bb2817855e78ac3c5a3145dd9834137f1c4a0a9c30392caa51fbd9f6904a821ba4dced474975a759bc8281abf40984914
6
+ metadata.gz: 15fde764961b367d16dbf4bda0d760e869fab76ba2bc23b493d0b6a08e9ef0d2f67ec85063ce78a7cf96b4eb99a4db76a60d801558a79784e5972e8081190632
7
+ data.tar.gz: 9a51f11a5d53e67bc76f9530d3ee34d5945c62675e4bd69bddecb7899d0304714186b333aa8ce524bee374aa14fec81135799727e9ac4def9898e8c2e561db31
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- grape-app (0.3.5)
4
+ grape-app (0.3.9)
5
5
  activesupport
6
6
  activesupport-json_encoder
7
7
  grape
@@ -51,7 +51,7 @@ GEM
51
51
  i18n (0.7.0)
52
52
  ice_nine (0.11.1)
53
53
  json (1.8.3)
54
- minitest (5.8.0)
54
+ minitest (5.8.1)
55
55
  multi_json (1.11.2)
56
56
  multi_xml (0.5.5)
57
57
  rack (1.6.4)
data/grape-app.gemspec CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = 'grape-app'
5
- s.version = '0.3.5'
5
+ s.version = '0.3.9'
6
6
  s.authors = ['Black Square Media Ltd']
7
7
  s.email = ['info@blacksquaremedia.com']
8
8
  s.summary = %{Stanalone Grape API apps}
@@ -1,7 +1,7 @@
1
1
  module Grape::App::Helpers::Params
2
2
 
3
3
  # Scope declared params
4
- # @return [Hashie::Mash] decalred params only
4
+ # @return [Hashie::Mash] declared params only
5
5
  def declared_params
6
6
  declared(params, include_missing: false)
7
7
  end
@@ -7,8 +7,11 @@ if defined?(ActiveRecord)
7
7
  require 'yaml'
8
8
  require 'erb'
9
9
 
10
- configurations = YAML.load(ERB.new(Grape::App.root.join('config', 'database.yml').read).result)
11
- configurations[Grape::App.env.to_s]['url'] = ENV['DATABASE_URL'] if ENV['DATABASE_URL']
10
+ configurations = YAML.load(ERB.new(Grape::App.root.join('config', 'database.yml').read).result) || {}
11
+ if ENV['DATABASE_URL']
12
+ configurations[Grape::App.env.to_s] ||= {}
13
+ configurations[Grape::App.env.to_s]['url'] ||= ENV['DATABASE_URL']
14
+ end
12
15
 
13
16
  ActiveRecord::Base.configurations = configurations
14
17
  ActiveRecord::Base.default_timezone = :utc
@@ -0,0 +1 @@
1
+ require 'grape/app/strong_parameters'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: grape-app
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.5
4
+ version: 0.3.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - Black Square Media Ltd
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-09-03 00:00:00.000000000 Z
11
+ date: 2015-10-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: grape
@@ -189,6 +189,7 @@ files:
189
189
  - lib/grape/app/templates/config/environments/production.rb
190
190
  - lib/grape/app/templates/config/environments/test.rb
191
191
  - lib/grape/app/templates/config/initializers/.gitkeep
192
+ - lib/grape/app/templates/config/initializers/strong_parameters.rb
192
193
  - lib/grape/app/templates/config/locales/en.yml
193
194
  - lib/grape/app/templates/db/seeds.rb
194
195
  - lib/grape/app/templates/spec/spec_helper.rb