-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added schoology api's. #5
base: dev/schoology
Are you sure you want to change the base?
Added schoology api's. #5
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Run eslint once across the files that have changed. I noticed some indentation differences and double-quotes being used for strings. You can edit the rules of the eslintrc file (if there are any differences) to be similar to our other repos to make sure that the style is consistent
} | ||
|
||
static getNonce( nonceLength ) { | ||
return uuidV4().replace(/-/g, '').slice(-16); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should use the nonceLength
param to decide the length
*/ | ||
handleError(err, code) { | ||
if (err.response) { | ||
switch (err.response.status) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need to handle the case where the user's oauth token expires. You can have a look at how canvas handles it, ideally we'd try to refresh it automatically a few times before throwing an error (which would take them through the oauth flow again)
} | ||
} | ||
|
||
isTokenExpired(err) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think this would apply for schoology, this was a canvas-specific condition
No description provided.