ruby on rails - Devise CustomFailure and mount in routes, bad redirect -
i'm using customfailure
class shown in doc (here) redirect our sign in page when unauthenticated:
class customfailure < devise::failureapp include localization def redirect_url url_for(controller: "/public/sessions", action: :new, locale: locale_to_params(i18n.locale)) end # need override respond eliminate recall def respond if http_auth? http_auth else redirect end end end
so redirects http://www.acmecorp.com/en/signin
, sidekiq panel in routes.rb
:
authenticate :user, lambda { |u| u.super_admin? } require "sidekiq/web" mount sidekiq::web => "/sidekiq" end
i redirected http://www.acmecorp.com/sidekiq/en/signin
instead of http://www.acmecorp.com/en/signin
. reason why redirect not rid of /sidekiq
part?
thanks!
Comments
Post a Comment