Sha256: e6edcf56bcba3fb1cca404b8453a40d71bd9f539a75442485207dc40582fea91
Contents?: true
Size: 363 Bytes
Versions: 17
Compression:
Stored size: 363 Bytes
Contents
module EgovUtils class Principal < ApplicationRecord self.abstract_class = true serialize :roles, Array def reload(*attrs) @auth_source = nil super end def has_role?(role) roles.include?(role) end def auth_source @auth_source ||= EgovUtils::AuthSource.new(provider) if provider.present? end end end
Version data entries
17 entries across 17 versions & 1 rubygems