allow mods to resend confirmation emails for other users
This commit is contained in:
@@ -139,7 +139,7 @@ class UsersController < ApplicationController
|
||||
end
|
||||
|
||||
def resend_mail
|
||||
if @user.is?(current_user) && !confirmed?
|
||||
if (@user.is?(current_user) || mod) && !confirmed?
|
||||
RedstonerMailer.register_mail(@user, false).deliver_now
|
||||
flash[:notice] = "Check your inbox for the confirmation mail."
|
||||
else
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
<% end %>
|
||||
|
||||
<% if !@user.confirmed? %>
|
||||
<% if @user.is?(current_user) %>
|
||||
<% if @user.is?(current_user) || mod? %>
|
||||
<span class="user-unconfirmed">Please confirm your email <u><%= @user.email %></u> !</span>
|
||||
<%= button_to "Resend the confirmation mail", resend_mail_user_path, class: "btn dark", form_class: "inline-block", data: {confirm: "Did you check your spam folder?"} %>
|
||||
<% else %>
|
||||
|
||||
Reference in New Issue
Block a user