Update iframe url parameter variables

This commit is contained in:
Kristin Aoki
2021-07-29 14:09:51 -04:00
parent c592753182
commit 4be725b4c2

View File

@@ -92,7 +92,7 @@ function Unit({
const unit = useModel('units', id);
const { authenticatedUser } = useContext(AppContext);
const view = authenticatedUser ? 'student_view' : 'public_view';
let iframeUrl = `${getConfig().LMS_BASE_URL}/xblock/${unit.decoded_id}?show_title=0&show_bookmark_button=0&recheck_access=1&view=${view}`;
let iframeUrl = `${getConfig().LMS_BASE_URL}/xblock/${(unit.decoded_id || id)}?show_title=0&show_bookmark_button=0&recheck_access=1&view=${view}`;
if (format) {
iframeUrl += `&format=${format}`;
}