mirror of
https://github.com/koreanbots/core.git
synced 2025-12-15 14:10:22 +00:00
fix: catching error for ga blocked
This commit is contained in:
parent
f94d436c2f
commit
fa6c3722be
@ -12,8 +12,11 @@ export function handlePWA(): boolean {
|
||||
if (window.navigator.standalone || window.matchMedia(mqStandAlone).matches) {
|
||||
displayMode = 'standalone'
|
||||
}
|
||||
window?.ga('set', 'dimension1', displayMode)
|
||||
|
||||
try {
|
||||
window.ga('set', 'dimension1', displayMode)
|
||||
} catch {
|
||||
console.warn('GA Failed')
|
||||
}
|
||||
return displayMode === 'standalone'
|
||||
}
|
||||
export function formatNumber(value: number):string {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user