giocopro 0.0.2 → 0.0.3

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,8 +1,8 @@
1
1
  require 'rails/generators/base'
2
- require 'generators/gioco_pro/model_generator'
3
- require 'generators/gioco_pro/generator_instructions'
2
+ require 'generators/giocopro/model_generator'
3
+ require 'generators/giocopro/generator_instructions'
4
4
 
5
- module GiocoPro
5
+ module Giocopro
6
6
  class SetupGenerator < Rails::Generators::Base
7
7
  include ModelGenerator
8
8
  include GeneratorInstructions
data/lib/giocopro.rb CHANGED
@@ -1,11 +1,14 @@
1
1
  require 'json'
2
2
  require 'net/http'
3
3
 
4
- module GiocoPro
5
- class GiocoPro
4
+ module Giocopro
5
+ class Giocopro
6
6
  def initialize(token=false)
7
7
  @http = Net::HTTP.new('app.gioco.pro')
8
8
  @headers = {'Content-Type' =>'application/json', 'Token' =>(token) ? token : ENV['GIOCOPRO_TOKEN']}
9
+ if token.nil? && ENV['GIOCOPRO_TOKEN'].nil?
10
+ return true # nothing should happen
11
+ end
9
12
  end
10
13
 
11
14
  def get_resource(aid)
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: giocopro
3
3
  version: !ruby/object:Gem::Version
4
- hash: 27
4
+ hash: 25
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 0
9
- - 2
10
- version: 0.0.2
9
+ - 3
10
+ version: 0.0.3
11
11
  platform: ruby
12
12
  authors:
13
13
  - Gioco Pro
@@ -20,7 +20,7 @@ default_executable:
20
20
  dependencies: []
21
21
 
22
22
  description: Gioco Pro gem is the SDK of Gioco Pro service a easy way to implement gamification based on plug and play concept. Doesn't matter if you already have a full and functional database, Gioco will smoothly integrate everything and provide all methods and analytics that you might need.
23
- email: joaomdmoura@gioco.pro
23
+ email: admin@gioco.pro
24
24
  executables: []
25
25
 
26
26
  extensions: []
@@ -29,9 +29,9 @@ extra_rdoc_files: []
29
29
 
30
30
  files:
31
31
  - lib/giocopro.rb
32
- - lib/generators/gioco_pro/generator_instructions.rb
33
- - lib/generators/gioco_pro/model_generator.rb
34
- - lib/generators/gioco_pro/setup_generator.rb
32
+ - lib/generators/giocopro/generator_instructions.rb
33
+ - lib/generators/giocopro/model_generator.rb
34
+ - lib/generators/giocopro/setup_generator.rb
35
35
  - lib/generators/templates/config.rb
36
36
  - lib/giocopro/gioco_resource.rb
37
37
  - init.rb