Class: SolidQueueMonitor::AuthenticationService

Inherits:
Object
  • Object
show all
Defined in:
app/services/solid_queue_monitor/authentication_service.rb

Class Method Summary collapse

Class Method Details

.authenticate(username, password) ⇒ Object



3
4
5
6
7
8
# File 'app/services/solid_queue_monitor/authentication_service.rb', line 3

def self.authenticate(username, password)
  return true unless SolidQueueMonitor.authentication_enabled
  
  username == SolidQueueMonitor.username && 
  password == SolidQueueMonitor.password
end

.authentication_required?Boolean

Returns:

  • (Boolean)


10
11
12
# File 'app/services/solid_queue_monitor/authentication_service.rb', line 10

def self.authentication_required?
  SolidQueueMonitor.authentication_enabled
end