Merged in feature/IO-1828-Beta-Updates-To-Test (pull request #1190)
- update handleBeta
This commit is contained in:
@@ -58,9 +58,8 @@ export function App({
|
|||||||
if (!navigator.onLine) {
|
if (!navigator.onLine) {
|
||||||
setOnline(false);
|
setOnline(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
handleBeta();
|
|
||||||
checkUserSession();
|
checkUserSession();
|
||||||
|
handleBeta();
|
||||||
}, [checkUserSession, setOnline]);
|
}, [checkUserSession, setOnline]);
|
||||||
|
|
||||||
//const b = Grid.useBreakpoint();
|
//const b = Grid.useBreakpoint();
|
||||||
|
|||||||
@@ -26,12 +26,14 @@ export const handleBeta = () => {
|
|||||||
if (isBeta && !currentHostName.startsWith('beta')) {
|
if (isBeta && !currentHostName.startsWith('beta')) {
|
||||||
const href= `${window.location.protocol}//beta.${currentHostName}${window.location.pathname}${window.location.search}${window.location.hash}`;
|
const href= `${window.location.protocol}//beta.${currentHostName}${window.location.pathname}${window.location.search}${window.location.hash}`;
|
||||||
window.location.replace(href);
|
window.location.replace(href);
|
||||||
|
window.location.reload(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Beta is not enabled, but the current host name does start with beta.
|
// Beta is not enabled, but the current host name does start with beta.
|
||||||
else if (!isBeta && currentHostName.startsWith('beta')) {
|
else if (!isBeta && currentHostName.startsWith('beta')) {
|
||||||
const href = `${window.location.protocol}//${currentHostName.replace('beta.', '')}${window.location.pathname}${window.location.search}${window.location.hash}`;
|
const href = `${window.location.protocol}//${currentHostName.replace('beta.', '')}${window.location.pathname}${window.location.search}${window.location.hash}`;
|
||||||
window.location.replace(href);
|
window.location.replace(href);
|
||||||
|
window.location.reload(true)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
export default handleBeta;
|
export default handleBeta;
|
||||||
|
|||||||
Reference in New Issue
Block a user