panda_pal 5.16.10 → 5.16.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 4ef7c93697588b49dcc326dd6819f38b2564b3e6be3a70d305ad9daf8e18e4d0
4
- data.tar.gz: 623793293fc139c1d190bb96649bfa05f9ba5ece0be6e3f811cd800dabaea8bb
3
+ metadata.gz: 0442d4ba09d95ef51337e42da67e084ced8399cdaa025772a8bb74efc5d7c772
4
+ data.tar.gz: 80999b109c85aab72981be87b5d61be2fd4bf1a42ac37d036bf6fcdb4f2d7c6d
5
5
  SHA512:
6
- metadata.gz: 111e04be6bcfa342871ea4eac96b18c67ca8e510af3ab2d9cac35f1896eb8145235bf6901c2f803bcdca45c269907dc8b0f71b8f2545398b1d47ef5516bc3ef5
7
- data.tar.gz: 877610ab2856f60eb67b9839bae270fbca309f0ffe6c10ec4bfdf98f77bfdbdfe261361bdb4a490e693b7fc8bdf25e5c5e5b71a34b403e4e9aa7966ecb9c75cd
6
+ metadata.gz: fb3aa209bef32fc3042ef04a25601fd9a768e64e9793632076d2f3ff8d5428aa4c7545ff9ab684071a7dda0c3aecc4cec8db58d5af005add8b815df21888046f
7
+ data.tar.gz: 4ead30f7c30fa32ff41e72e8389a9c46221c6d1ab8a4f7bd3c3a69565cf0d53fbf1d0001dfd7e14e289cd76e5303a003cd8d527a0c1a76f0ec636ce1a96f5e83
@@ -9,6 +9,7 @@ module PandaPal
9
9
  "https://sso.canvaslms.com",
10
10
  "https://sso.beta.canvaslms.com",
11
11
  "https://sso.test.canvaslms.com",
12
+ "https://sso.loadtest.instructure.com",
12
13
 
13
14
  # Deprecated (but still secure):
14
15
  "https://canvas.instructure.com",
@@ -167,13 +168,22 @@ module PandaPal
167
168
  lti_json["target_link_uri"]
168
169
  ]
169
170
 
171
+ canvas_ext = (lti_json["extensions"] || []).find { |ext| ext["platform"] == "canvas.instructure.com" }
172
+ placements = canvas_ext&.dig("settings", "placements") || []
173
+ placements.each do |p|
174
+ next unless p["target_link_uri"]
175
+ valid_redirect_uris << p["target_link_uri"].gsub(/\?.*$/, "")
176
+ end
177
+
178
+ valid_redirect_uris.uniq!
179
+
170
180
  prod_domain = PandaPal.lti_environments[:domain]
171
181
  if prod_domain.present?
172
182
  PandaPal.lti_environments.each do |env, domain|
173
183
  env = env.to_s
174
184
  next unless env.ends_with?("_domain")
175
185
  env = env.split('_')[0]
176
- valid_redirect_uris << lti_json["target_link_uri"].gsub(prod_domain, domain)
186
+ valid_redirect_uris += valid_redirect_uris.map{|uri| uri.gsub(prod_domain, domain)}
177
187
  end
178
188
  end
179
189
 
@@ -17,6 +17,6 @@ module PandaPal::Helpers::RouteHelper
17
17
  lti_options[:route_helper_key] = path.split('/').reject(&:empty?).join('_')
18
18
  post(path, options.dup, &block)
19
19
  get(path, options.dup, &block)
20
- PandaPal::stage_placement(nav, lti_options)
20
+ PandaPal::stage_navigation(nav, lti_options)
21
21
  end
22
22
  end
@@ -1,3 +1,3 @@
1
1
  module PandaPal
2
- VERSION = "5.16.10"
2
+ VERSION = '5.16.12'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: panda_pal
3
3
  version: !ruby/object:Gem::Version
4
- version: 5.16.10
4
+ version: 5.16.12
5
5
  platform: ruby
6
6
  authors:
7
7
  - Instructure CustomDev