Skip to content
Permalink

Comparing changes

This is a direct comparison between two commits made in this repository or its related repositories. View the default comparison for this range or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: ManageIQ/manageiq
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: ced98f22047b85895453b32000f8c06860046229
Choose a base ref
..
head repository: ManageIQ/manageiq
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 9d83e12436b20979c589909e15936ad0695b41f6
Choose a head ref
Showing with 1 addition and 6 deletions.
  1. +1 −6 app/models/authenticator.rb
7 changes: 1 addition & 6 deletions app/models/authenticator.rb
Original file line number Diff line number Diff line change
@@ -11,12 +11,7 @@ def self.for(config, username = nil)
def self.validate_config(config)
return [] if config[:mode] == "none"

authenticator = self.for(config)
if authenticator
[:mode, "authentication type, #{config[:mode].inspect}, invalid. Should be one of: #{valid_modes.join(", ")}"]
else
authenticator.validate_config
end
self.for(config).try(:validate_config) || [:mode, "authentication type, #{config[:mode].inspect}, invalid. Should be one of: #{valid_modes.join(", ")}"]
end

private_class_method def self.valid_modes