module Rakuna::Authentication::GitHub::Organization

Public Instance Methods

is_authorized?(authorization_header = nil) click to toggle source
# File lib/rakuna/authentication/github/organization.rb, line 12
def is_authorized?(authorization_header = nil)
  organizations.any? { |org| whitelist.include? org.login }
end

Private Instance Methods

organizations() click to toggle source
# File lib/rakuna/authentication/github/organization.rb, line 34
def organizations
  @organizations ||= github.organizations
end
user() click to toggle source
# File lib/rakuna/authentication/github/organization.rb, line 24
def user
  @user ||= github.user
end
username() click to toggle source
# File lib/rakuna/authentication/github/organization.rb, line 29
def username
  @username ||= user.login
end
whitelist() click to toggle source
# File lib/rakuna/authentication/github/organization.rb, line 19
def whitelist
  []
end