app/controllers/application_controller.rb
# Redirect to location that triggered authentication or to homepage
Redirect to location that triggered authentication or to homepage
Redirect to location that triggered authentication or to homepage
def after_sign_in_path_for(resource)
    session.options[:id] = session.instance_variable_get(:@by).generate_sid
    session.options[:renew] = false
    resource.update_attributes(unique_session_id: session.id)
    gpp_collection = Collection.where(title: 'Government Publications').first
    path = gpp_collection.present? ? hyrax.collection_path(gpp_collection) : root_path
    stored_location_for(resource) || path
  end
def after_sign_in_path_for ( resource ) session . options [ :id ] = session . instance_variable_get ( :@by ) . generate_sid session . options [ :renew ] = false resource . update_attributes ( unique_session_id : session . id ) gpp_collection = Collection . where ( title : 'Government Publications' ) . first path = gpp_collection . present? ? hyrax . collection_path ( gpp_collection ) : root_path stored_location_for ( resource ) || path end
Redirect to location that triggered authentication or to homepage
Redirect to location that triggered authentication or to homepage
# Generate new session id and update in user.unique_session_id # Get path to Government Publications collection or homepage if collection not found
resource
<not_specific>