]> cat aescling's git repositories - mastodon.git/commitdiff
When registrations closed, link "Sign up" to joinmastodon.org (#8395)
authorEugen Rochko <eugen@zeonfederated.com>
Thu, 23 Aug 2018 17:11:41 +0000 (19:11 +0200)
committerGitHub <noreply@github.com>
Thu, 23 Aug 2018 17:11:41 +0000 (19:11 +0200)
Fix #8393

app/views/auth/shared/_links.html.haml
app/views/layouts/public.html.haml

index 08b38509272f1bac46290669edd0e3d73cdffde2..516c625a6b564cfe2877e77c377dab80802c1b8d 100644 (file)
@@ -3,7 +3,7 @@
     %li= link_to t('auth.login'), new_session_path(resource_name)
 
   - if devise_mapping.registerable? && controller_name != 'registrations'
-    %li= link_to t('auth.register'), new_registration_path(resource_name)
+    %li= link_to t('auth.register'), open_registrations? ? new_registration_path(resource_name) : 'https://joinmastodon.org/#getting-started'
 
   - if devise_mapping.recoverable? && controller_name != 'passwords' && controller_name != 'registrations'
     %li= link_to t('auth.forgot_password'), new_password_path(resource_name)
index ca9dac8bb0308bae9060a54f69e7b7f363d4f665..6bf7efb2376b1d5279ea0f5bab4d7a5f38b30f66 100644 (file)
@@ -14,7 +14,7 @@
             = link_to t('settings.back'), root_url, class: 'nav-link nav-button webapp-btn'
           - else
             = link_to t('auth.login'), new_user_session_path, class: 'webapp-btn nav-link nav-button'
-            = link_to t('auth.register'), new_user_registration_path, class: 'webapp-btn nav-link nav-button'
+            = link_to t('auth.register'), open_registrations? ? new_user_registration_path : 'https://joinmastodon.org/#getting-started', class: 'webapp-btn nav-link nav-button'
 
     .container= yield