diff --git a/app/controllers/user_upgrades_controller.rb b/app/controllers/user_upgrades_controller.rb index e295b16a1..1c01cc0e0 100644 --- a/app/controllers/user_upgrades_controller.rb +++ b/app/controllers/user_upgrades_controller.rb @@ -1,5 +1,5 @@ class UserUpgradesController < ApplicationController - before_action :member_only, :only => [:new, :show] + before_action :member_only, only: [:show] helper_method :user skip_before_action :verify_authenticity_token, only: [:create] diff --git a/app/views/user_upgrades/new.html.erb b/app/views/user_upgrades/new.html.erb index ac750e72f..f27bd35d9 100644 --- a/app/views/user_upgrades/new.html.erb +++ b/app/views/user_upgrades/new.html.erb @@ -106,7 +106,9 @@ <% if Danbooru.config.stripe_publishable_key %> - <% if CurrentUser.safe_mode? %> + <% if CurrentUser.is_anonymous? %> +

<%= link_to "Sign up", new_user_path %> or <%= link_to "login", new_session_path(url: new_user_upgrade_path) %> first to upgrade your account.

+ <% elsif CurrentUser.safe_mode? %> <%= render "stripe_payment" %> <% else %> <%= render "stripe_payment_safebooru" %>