Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 7 additions & 3 deletions app/controllers/orgs_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,10 @@ def admin_update
# This action is used by installations that have the following config enabled:
# Rails.configuration.x.shibboleth.use_filtered_discovery_service
def shibboleth_ds
redirect_to root_path unless current_user.nil?
unless current_user.nil?
redirect_to root_path
return
end

@user = User.new
# Display the custom Shibboleth discovery service page.
Expand All @@ -106,12 +109,13 @@ def shibboleth_ds

# Disabling the rubocop check here because it would not be clear what happens
# if the ``@orgs` array has items ... it renders the shibboleth_ds view
# rubocop:disable Style/GuardClause
# rubocop:disable Style/GuardClause, Style/RedundantReturn
if @orgs.empty?
flash.now[:alert] = _("No organisations are currently registered.")
redirect_to user_shibboleth_omniauth_authorize_path
return
end
# rubocop:enable Style/GuardClause
# rubocop:enable Style/GuardClause, Style/RedundantReturn
end

# This action is used to redirect a user to the Shibboleth IdP
Expand Down
2 changes: 1 addition & 1 deletion app/controllers/super_admin/themes_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ def destroy
redirect_to super_admin_themes_path, notice: msg
else
flash.now[:alert] = failure_message(@theme, _("delete"))
redner :edit
render :edit
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good catch

end
end

Expand Down