mirror of
https://github.com/danielsogl/awesome-cordova-plugins.git
synced 2025-01-19 08:32:52 +08:00
fix(core): wrapEventObservable (#2660)
* fix wrapEventObservable * fix lint
This commit is contained in:
parent
110fb7e8e1
commit
bd345818f8
@ -167,11 +167,7 @@ function wrapObservable(
|
|||||||
* @returns {Observable}
|
* @returns {Observable}
|
||||||
*/
|
*/
|
||||||
function wrapEventObservable(event: string, element: any): Observable<any> {
|
function wrapEventObservable(event: string, element: any): Observable<any> {
|
||||||
if (element) {
|
element = element ? get(window, element) : window;
|
||||||
get(window, element);
|
|
||||||
} else {
|
|
||||||
element = window;
|
|
||||||
}
|
|
||||||
return fromEvent(element, event);
|
return fromEvent(element, event);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user