mirror of
https://github.com/mastodon/mastodon.git
synced 2024-12-29 14:35:06 +01:00
Change ability to navigate of unconfirmed users (#33209)
This commit is contained in:
parent
ca45f896dd
commit
796dd57e1b
@ -70,7 +70,13 @@ class ApplicationController < ActionController::Base
|
||||
end
|
||||
|
||||
def require_functional!
|
||||
redirect_to edit_user_registration_path unless current_user.functional?
|
||||
return if current_user.functional?
|
||||
|
||||
if current_user.confirmed?
|
||||
redirect_to edit_user_registration_path
|
||||
else
|
||||
redirect_to auth_setup_path
|
||||
end
|
||||
end
|
||||
|
||||
def skip_csrf_meta_tags?
|
||||
|
@ -78,5 +78,3 @@
|
||||
|
||||
.actions
|
||||
= f.button :button, @invite.present? ? t('auth.register') : sign_up_message, type: :submit
|
||||
|
||||
.form-footer= render 'auth/shared/links'
|
||||
|
@ -27,5 +27,3 @@
|
||||
- accept_path = @invite_code.present? ? public_invite_url(invite_code: @invite_code, accept: @accept_token) : new_user_registration_path(accept: @accept_token)
|
||||
= link_to t('auth.rules.accept'), accept_path, class: 'button'
|
||||
= link_to t('auth.rules.back'), root_path, class: 'button button-tertiary'
|
||||
|
||||
.form-footer= render 'auth/shared/links'
|
||||
|
@ -11,17 +11,17 @@
|
||||
|
||||
= render 'shared/error_messages', object: @user
|
||||
|
||||
%p.lead
|
||||
%details
|
||||
%summary.lead
|
||||
%strong= t('auth.setup.link_not_received')
|
||||
|
||||
%p.lead= t('auth.setup.email_below_hint_html')
|
||||
|
||||
.fields-group
|
||||
= f.input :email,
|
||||
hint: false,
|
||||
input_html: { 'aria-label': t('simple_form.labels.defaults.email'), autocomplete: 'off' },
|
||||
input_html: { 'aria-label': t('simple_form.labels.defaults.email'), autocomplete: 'off', placeholder: t('simple_form.labels.defaults.email') },
|
||||
required: true
|
||||
|
||||
.actions
|
||||
= f.button :button, t('auth.resend_confirmation'), type: :submit, class: 'button timer-button', disabled: true
|
||||
|
||||
.form-footer= render 'auth/shared/links'
|
||||
|
@ -1157,7 +1157,7 @@ en:
|
||||
set_new_password: Set new password
|
||||
setup:
|
||||
email_below_hint_html: Check your spam folder, or request another one. You can correct your email address if it's wrong.
|
||||
email_settings_hint_html: Click the link we sent you to verify %{email}. We'll wait right here.
|
||||
email_settings_hint_html: Click the link we sent to %{email} to begin using Mastodon. We'll wait right here.
|
||||
link_not_received: Didn't get a link?
|
||||
new_confirmation_instructions_sent: You will receive a new email with the confirmation link in a few minutes!
|
||||
title: Check your inbox
|
||||
@ -1166,7 +1166,7 @@ en:
|
||||
title: Login to %{domain}
|
||||
sign_up:
|
||||
manual_review: Sign-ups on %{domain} go through manual review by our moderators. To help us process your registration, write a bit about yourself and why you want an account on %{domain}.
|
||||
preamble: With an account on this Mastodon server, you'll be able to follow any other person on the network, regardless of where their account is hosted.
|
||||
preamble: With an account on this Mastodon server, you'll be able to follow any other person on the fediverse, regardless of where their account is hosted.
|
||||
title: Let's get you set up on %{domain}.
|
||||
status:
|
||||
account_status: Account status
|
||||
|
@ -34,7 +34,7 @@ RSpec.describe 'Log in' do
|
||||
it 'A unconfirmed user is able to log in' do
|
||||
fill_in_auth_details(email, password)
|
||||
|
||||
expect(subject).to have_css('div.admin-wrapper')
|
||||
expect(subject).to have_css('.title', text: I18n.t('auth.setup.title'))
|
||||
end
|
||||
end
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user