fixes failing email specs
Conflicts: app/models/user.rb fixes missing i18n entry fixes badly done merge fixes i18n issues force build to start
This commit is contained in:
@@ -61,4 +61,4 @@ Code published under AFFERO GPL v3 (see [LICENSE-AGPLv3.txt](LICENSE-AGPLv3.txt)
|
||||
|
||||
## Contributions
|
||||
|
||||
See [CONTRIBUTING_EN.md](CONTRIBUTING_EN.md)
|
||||
See [CONTRIBUTING_EN.md](CONTRIBUTING_EN.md)
|
||||
@@ -83,7 +83,7 @@ class ApplicationController < ActionController::Base
|
||||
|
||||
def ensure_signup_complete
|
||||
if user_signed_in? &&
|
||||
current_user.pending_finish_signup? &&
|
||||
current_user.registering_with_oauth &&
|
||||
%w(finish_signup do_finish_signup).exclude?(action_name)
|
||||
redirect_to finish_signup_path
|
||||
end
|
||||
|
||||
@@ -13,7 +13,7 @@ class Users::OmniauthCallbacksController < Devise::OmniauthCallbacksController
|
||||
end
|
||||
|
||||
def after_sign_in_path_for(resource)
|
||||
if resource.pending_finish_signup?
|
||||
if resource.registering_with_oauth
|
||||
finish_signup_path
|
||||
else
|
||||
super(resource)
|
||||
|
||||
@@ -183,8 +183,8 @@ class User < ActiveRecord::Base
|
||||
self[:locale] ||= I18n.default_locale.to_s
|
||||
end
|
||||
|
||||
def pending_finish_signup?
|
||||
email.blank? && unconfirmed_email.blank?
|
||||
def confirmation_required?
|
||||
super && !registering_with_oauth
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
Reference in New Issue
Block a user