MOBILE-4653 delegate: Fix regression in hasHandlers
parent
fd78763c24
commit
00d92e1f0e
|
@ -76,7 +76,7 @@ export class CoreSortedDelegate<
|
|||
* @inheritdoc
|
||||
*/
|
||||
hasHandlers(enabled = false): boolean {
|
||||
return enabled ? !!this.sortedHandlers.length : !!this.handlers.length;
|
||||
return enabled ? !!this.sortedHandlers.length : !!Object.keys(this.handlers).length;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -214,7 +214,7 @@ export class CoreDelegate<HandlerType extends CoreDelegateHandler> {
|
|||
* @returns True if there's any registered handler, false otherwise.
|
||||
*/
|
||||
hasHandlers(enabled = false): boolean {
|
||||
return enabled ? !!this.enabledHandlers.length : !!this.handlers.length;
|
||||
return enabled ? !!Object.keys(this.enabledHandlers).length : !!Object.keys(this.handlers).length;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue