Skip to content

Commit

Permalink
feat: new checkApp origin requirement
Browse files Browse the repository at this point in the history
  • Loading branch information
zacharis278 committed Dec 12, 2023
1 parent 3a04fbf commit 2252269
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/data/messages/proctorio.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,12 @@
* vendor-specific integrations long term. As of now these events
* will trigger on ANY lti integration, not just Proctorio.
*/
import { getConfig } from '@edx/frontend-platform';

export async function checkAppStatus() {
return new Promise((resolve, reject) => {
const handleResponse = event => {
if (event.origin === window.location.origin) {
if (event.origin === getConfig().EXAMS_BASE_URL) {
window.removeEventListener('message', handleResponse);
if (event?.data?.active) {
resolve();
Expand Down

0 comments on commit 2252269

Please sign in to comment.