canvas_sync 0.27.7 → 0.27.10
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 +4 -4
- data/lib/canvas_sync/concerns/ability_helper.rb +5 -0
- data/lib/canvas_sync/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 11f8cb2b6cbea897aacf6bd2a352fb5dd3a7d179281070bad4c6c10f90993b30
|
|
4
|
+
data.tar.gz: ea7421a010c1e3078a9b28e6d1503333c53214142c6111a7aa06ef23d13cdb82
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: c569c7f78a291537c728a183d7598a594a9983a4be9febbde7b2c084d6207a65a8e4f640aa9f93cee36656bbaa3b156417783d405ce23626138fc77d5dfc83cc
|
|
7
|
+
data.tar.gz: 381f98ec9099bf3f845ed0e222587f69f868c30c1bb3966b85826d6c65405d51e98ddcf8487aacf19c07584dde3fc84e4df532938897d498e1f23a0c8724aaf6
|
|
@@ -35,6 +35,7 @@ module CanvasSync::Concerns
|
|
|
35
35
|
|
|
36
36
|
def launch_context
|
|
37
37
|
return nil unless panda_pal_session.present?
|
|
38
|
+
return @launch_context if defined?(@launch_context)
|
|
38
39
|
|
|
39
40
|
@launch_context ||= begin
|
|
40
41
|
if panda_pal_session.lti_launch_placement == "global_navigation"
|
|
@@ -57,6 +58,8 @@ module CanvasSync::Concerns
|
|
|
57
58
|
|
|
58
59
|
@launch_account ||= load_canvas_model(::Account, panda_pal_session.get_lti_cust_param('custom_canvas_account_id'))
|
|
59
60
|
|
|
61
|
+
@launch_account ||= ::Account.find_by(canvas_parent_account_id: nil)
|
|
62
|
+
|
|
60
63
|
@launch_account
|
|
61
64
|
end
|
|
62
65
|
|
|
@@ -64,6 +67,8 @@ module CanvasSync::Concerns
|
|
|
64
67
|
|
|
65
68
|
def load_canvas_model(model, canvas_id)
|
|
66
69
|
return nil unless model < CanvasSync::Record
|
|
70
|
+
return nil unless canvas_id.present?
|
|
71
|
+
return nil if canvas_id.is_a?(String) && canvas_id.include?('$')
|
|
67
72
|
|
|
68
73
|
if model.respond_to?(:find_or_jit_sync)
|
|
69
74
|
model.find_or_jit_sync(canvas_id)
|
data/lib/canvas_sync/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: canvas_sync
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.27.
|
|
4
|
+
version: 0.27.10
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Instructure CustomDev
|
|
@@ -413,14 +413,14 @@ dependencies:
|
|
|
413
413
|
requirements:
|
|
414
414
|
- - "~>"
|
|
415
415
|
- !ruby/object:Gem::Version
|
|
416
|
-
version: 0.
|
|
416
|
+
version: 0.2.0
|
|
417
417
|
type: :runtime
|
|
418
418
|
prerelease: false
|
|
419
419
|
version_requirements: !ruby/object:Gem::Requirement
|
|
420
420
|
requirements:
|
|
421
421
|
- - "~>"
|
|
422
422
|
- !ruby/object:Gem::Version
|
|
423
|
-
version: 0.
|
|
423
|
+
version: 0.2.0
|
|
424
424
|
email:
|
|
425
425
|
- pseng@instructure.com
|
|
426
426
|
executables: []
|