Skip to content

Commit

Permalink
add edit_user_registration path
Browse files Browse the repository at this point in the history
  • Loading branch information
rawOrlando committed Jan 2, 2024
1 parent 047efe3 commit e8ef43e
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions config/routes.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Rails.application.routes.draw do
concern :searchable, Blacklight::Routes::Searchable.new

mount Blacklight::Oembed::Engine, at: 'oembed'
mount Riiif::Engine => '/images', as: 'riiif'
root to: 'spotlight/exhibits#index'
Expand All @@ -16,19 +16,23 @@
concerns :searchable
end

if Rails.env.production? # || Rails.env.tdldev?
# todo why are these different maybe just have one
if Rails.env.production? || Rails.env.tdldev?
devise_for :users, controllers: { omniauth_callbacks: "omniauthcallbacks" }, skip: [:sessions]
devise_scope :user do
get 'users/sign_in', to: 'omniauth#new'
post 'sign_in', to: 'omniauth#new', as: :new_user_session
post 'sign_in', to: 'omniauth_callbacks#shibboleth', as: :new_session
get 'sign_out', to: 'devise/sessions#destroy', as: :destroy_user_session
get 'users/edit' => 'devise/registrations#edit', :as => 'edit_user_registration'
end
else
# TODO: maybe the issue is here
devise_for :users
devise_scope :user do
get 'users/sign_in', to: 'omniauth#new'
get 'users/edit' => 'devise/registrations#edit', :as => 'edit_user_registration'

end

end
Expand Down

0 comments on commit e8ef43e

Please sign in to comment.