check iframe

This commit is contained in:
Jade (Rose) Rowland 2024-08-12 12:54:05 -04:00
parent d850726910
commit 926c893c4f

View File

@ -135,7 +135,11 @@ export async function shareCode(codeToShare) {
export const ReplContext = createContext(null);
export const isUdels = () => {
return window.parent?.location.pathname.includes('udels');
const isIframe = window.location !== window.parent.location;
if (isIframe) {
return false
}
return window.parent?.location?.pathname.includes('udels');
};
export const getAudioDevices = async () => {