Only use OTRS auth backend if endpoint exists.
This commit is contained in:
parent
6982183086
commit
11ff582c6d
1 changed files with 3 additions and 0 deletions
|
@ -1,6 +1,9 @@
|
||||||
class Auth::OTRS
|
class Auth::OTRS
|
||||||
def self.check( user, username, password, config )
|
def self.check( user, username, password, config )
|
||||||
|
|
||||||
|
endpoint = Setting.get('import_otrs_endpoint')
|
||||||
|
return false if !endpoint || endpoint.empty?
|
||||||
|
|
||||||
# connect to OTRS
|
# connect to OTRS
|
||||||
result = Import::OTRS.auth( username, password )
|
result = Import::OTRS.auth( username, password )
|
||||||
return false if !result
|
return false if !result
|
||||||
|
|
Loading…
Reference in a new issue