devise_invitable 0.2.1 → 0.2.2

Sign up to get free protection for your applications and to get access to all the features.
data/Rakefile CHANGED
@@ -12,7 +12,7 @@ begin
12
12
  gem.authors = ["Sergio Cambra"]
13
13
  gem.add_development_dependency 'mocha'
14
14
  gem.add_development_dependency 'webrat'
15
- gem.add_dependency 'devise', '~> 0.9.0'
15
+ gem.add_dependency 'devise', '~> 1.0.0'
16
16
  end
17
17
  Jeweler::GemcutterTasks.new
18
18
  rescue LoadError
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.2.1
1
+ 0.2.2
@@ -1,14 +1,19 @@
1
1
  class InvitationsController < ApplicationController
2
2
  include Devise::Controllers::InternalHelpers
3
- include Devise::Controllers::Common
4
3
 
5
4
  before_filter :authenticate_resource!, :only => [:new, :create]
6
5
  before_filter :require_no_authentication, :only => [:edit, :update]
7
6
  helper_method :after_sign_in_path_for
8
7
 
8
+ # GET /resource/invitation/new
9
+ def new
10
+ build_resource
11
+ render_with_scope :new
12
+ end
13
+
9
14
  # POST /resource/invitation
10
15
  def create
11
- self.resource = resource_class.send(send_instructions_with, params[resource_name])
16
+ self.resource = resource_class.send_invitation(params[resource_name])
12
17
 
13
18
  if resource.errors.empty?
14
19
  set_flash_message :notice, :send_instructions
@@ -36,9 +41,4 @@ class InvitationsController < ApplicationController
36
41
  render_with_scope :edit
37
42
  end
38
43
  end
39
-
40
- protected
41
- def send_instructions_with
42
- :send_invitation
43
- end
44
44
  end
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{devise_invitable}
8
- s.version = "0.2.1"
8
+ s.version = "0.2.2"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Sergio Cambra"]
12
- s.date = %q{2010-02-08}
12
+ s.date = %q{2010-02-12}
13
13
  s.description = %q{It adds support for send invitations by email (it requires to be authenticated) and accept the invitation setting the password}
14
14
  s.email = %q{sergio@entrecables.com}
15
15
  s.extra_rdoc_files = [
@@ -109,16 +109,16 @@ Gem::Specification.new do |s|
109
109
  if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then
110
110
  s.add_development_dependency(%q<mocha>, [">= 0"])
111
111
  s.add_development_dependency(%q<webrat>, [">= 0"])
112
- s.add_runtime_dependency(%q<devise>, ["~> 0.9.0"])
112
+ s.add_runtime_dependency(%q<devise>, ["~> 1.0.0"])
113
113
  else
114
114
  s.add_dependency(%q<mocha>, [">= 0"])
115
115
  s.add_dependency(%q<webrat>, [">= 0"])
116
- s.add_dependency(%q<devise>, ["~> 0.9.0"])
116
+ s.add_dependency(%q<devise>, ["~> 1.0.0"])
117
117
  end
118
118
  else
119
119
  s.add_dependency(%q<mocha>, [">= 0"])
120
120
  s.add_dependency(%q<webrat>, [">= 0"])
121
- s.add_dependency(%q<devise>, ["~> 0.9.0"])
121
+ s.add_dependency(%q<devise>, ["~> 1.0.0"])
122
122
  end
123
123
  end
124
124
 
data/test/test_helper.rb CHANGED
@@ -30,7 +30,7 @@ ActiveRecord::Schema.define(:version => 1) do
30
30
  end
31
31
  end
32
32
  class User
33
- devise :invitable
33
+ devise :authenticatable, :invitable
34
34
  end
35
35
  ActionController::Routing::Routes.draw do |map|
36
36
  map.devise_for :users
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: devise_invitable
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sergio Cambra
@@ -9,7 +9,7 @@ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
11
 
12
- date: 2010-02-08 00:00:00 +01:00
12
+ date: 2010-02-12 00:00:00 +01:00
13
13
  default_executable:
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
@@ -40,7 +40,7 @@ dependencies:
40
40
  requirements:
41
41
  - - ~>
42
42
  - !ruby/object:Gem::Version
43
- version: 0.9.0
43
+ version: 1.0.0
44
44
  version:
45
45
  description: It adds support for send invitations by email (it requires to be authenticated) and accept the invitation setting the password
46
46
  email: sergio@entrecables.com