aboutsummaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
Diffstat (limited to 'app')
-rw-r--r--app/lib/sso.rb2
-rw-r--r--app/lib/sso/from_discourse.rb3
-rw-r--r--app/models/user.rb4
3 files changed, 8 insertions, 1 deletions
diff --git a/app/lib/sso.rb b/app/lib/sso.rb
index ace2830..0939a7c 100644
--- a/app/lib/sso.rb
+++ b/app/lib/sso.rb
@@ -5,3 +5,5 @@ module SSO
require 'securerandom'
require_relative '../../config/initializers/sso_config'
end
+
+
diff --git a/app/lib/sso/from_discourse.rb b/app/lib/sso/from_discourse.rb
index 66742e2..a5df192 100644
--- a/app/lib/sso/from_discourse.rb
+++ b/app/lib/sso/from_discourse.rb
@@ -2,7 +2,8 @@
module SSO
class FromDiscourse
- attr_accessor :nonce, :token, :user_info, :status
+ attr_accessor :nonce, :token
+ attr_reader :request_uri, :user_info, :status
class << self
# See config/initializers/sso.rb
diff --git a/app/models/user.rb b/app/models/user.rb
new file mode 100644
index 0000000..f7e96a8
--- /dev/null
+++ b/app/models/user.rb
@@ -0,0 +1,4 @@
+class User < ApplicationRecord
+ has_many :agencies
+ has_many :agents, through: :agencies, source: :agent
+end