typus 3.0.5 → 3.0.6
Sign up to get free protection for your applications and to get access to all the features.
data/Gemfile.lock
CHANGED
@@ -6,8 +6,8 @@ class Admin::AccountController < Admin::BaseController
|
|
6
6
|
skip_before_filter :authenticate
|
7
7
|
skip_before_filter :set_locale
|
8
8
|
|
9
|
-
before_filter :sign_in?, :except => [:forgot_password, :show]
|
10
|
-
before_filter :new?, :only => [:forgot_password]
|
9
|
+
before_filter :sign_in?, :except => [:forgot_password, :send_password, :show]
|
10
|
+
before_filter :new?, :only => [:forgot_password, :send_password]
|
11
11
|
|
12
12
|
def new
|
13
13
|
flash[:notice] = Typus::I18n.t("Enter your email below to create the first user.")
|
@@ -20,8 +20,9 @@ class Admin::AccountController < Admin::BaseController
|
|
20
20
|
end
|
21
21
|
|
22
22
|
def forgot_password
|
23
|
-
|
23
|
+
end
|
24
24
|
|
25
|
+
def send_password
|
25
26
|
if user = Typus.user_class.find_by_email(params[:typus_user][:email])
|
26
27
|
url = admin_account_url(user.token)
|
27
28
|
Admin::Mailer.reset_password_link(user, url).deliver
|
data/config/routes.rb
CHANGED
@@ -8,7 +8,10 @@ Rails.application.routes.draw do
|
|
8
8
|
if Typus.authentication == :session
|
9
9
|
resource :session, :only => [:new, :create, :destroy], :controller => :session
|
10
10
|
resources :account, :only => [:new, :create, :show, :forgot_password] do
|
11
|
-
collection
|
11
|
+
collection do
|
12
|
+
get :forgot_password
|
13
|
+
post :send_password
|
14
|
+
end
|
12
15
|
end
|
13
16
|
end
|
14
17
|
|
data/lib/typus/version.rb
CHANGED
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: typus
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 11
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 3
|
8
8
|
- 0
|
9
|
-
-
|
10
|
-
version: 3.0.
|
9
|
+
- 6
|
10
|
+
version: 3.0.6
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Francesc Esplugas
|