Redirect fix

This commit is contained in:
Martin Lensment 2015-04-24 17:25:21 +03:00
parent 6d4df880eb
commit 22dffa0947

View file

@ -29,10 +29,11 @@ class Admin::CertificatesController < AdminController
def sign def sign
if @certificate.sign! if @certificate.sign!
flash[:notice] = I18n.t('record_updated') flash[:notice] = I18n.t('record_updated')
redirect_to [:admin, @api_user, @certificate]
else else
flash[:alert] = I18n.t('failed_to_update_record') flash.now[:alert] = I18n.t('failed_to_update_record')
render 'show'
end end
redirect_to [:admin, @api_user, @certificate]
end end
def revoke def revoke