You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Comparing the expiry to a timestamp is better than to the stored date because what really matters is when the learner did the thing, not when it was stored in the LRS.
Modify tincanlaunch_get_completion_state in lib.php to not just check if statements are returned but also cycle through the statements and make sure that at least one has a timestamp greater than the expiry date.
Currently the relevant code looks like this:
// If the statement exists, return true else return false.
if (!empty($statementquery->content) && $statementquery->success) {
$result = true;
} else {
$result = false;
}
Note: setting the result variable to true/false and then returning the variable is unneeded. We can just return true or false.
The text was updated successfully, but these errors were encountered:
Comparing the expiry to a timestamp is better than to the stored date because what really matters is when the learner did the thing, not when it was stored in the LRS.
Modify tincanlaunch_get_completion_state in lib.php to not just check if statements are returned but also cycle through the statements and make sure that at least one has a timestamp greater than the expiry date.
Currently the relevant code looks like this:
Note: setting the result variable to true/false and then returning the variable is unneeded. We can just return true or false.
The text was updated successfully, but these errors were encountered: