mirror of
https://github.com/danielsogl/awesome-cordova-plugins.git
synced 2026-04-13 00:00:10 +08:00
fix(ssr): fix window references
This commit is contained in:
@@ -391,7 +391,9 @@ export class PushObject {
|
||||
if (
|
||||
checkAvailability('PushNotification', 'init', 'PushNotification') === true
|
||||
) {
|
||||
this._objectInstance = window.PushNotification.init(options);
|
||||
if (typeof window !== 'undefined') {
|
||||
this._objectInstance = window.PushNotification.init(options);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user