mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 09:52:26 +01:00
fix environment detection regex
This commit is contained in:
parent
66b3b72c98
commit
451c05bcbb
@ -28,7 +28,7 @@ function getStack () {
|
|||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
const getEnvironmentType = (url = window.location.href) => {
|
const getEnvironmentType = (url = window.location.href) => {
|
||||||
if (url.match(/popup.html(?:\?.+)*$/)) {
|
if (url.match(/popup.html(?:#.*)*$/)) {
|
||||||
return ENVIRONMENT_TYPE_POPUP
|
return ENVIRONMENT_TYPE_POPUP
|
||||||
} else if (url.match(/home.html(?:\?.+)*$/) || url.match(/home.html(?:#.*)*$/)) {
|
} else if (url.match(/home.html(?:\?.+)*$/) || url.match(/home.html(?:#.*)*$/)) {
|
||||||
return ENVIRONMENT_TYPE_FULLSCREEN
|
return ENVIRONMENT_TYPE_FULLSCREEN
|
||||||
|
Loading…
Reference in New Issue
Block a user