Skip to content

Commit d8b83e4

Browse files
committed
fix: combine splice-and-push into just splice
1 parent afa78dd commit d8b83e4

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

packages/core/data/dom-events/dom-event.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -192,8 +192,7 @@ export class DOMEvent implements Event {
192192
* [Button, StackLayout, Page] // 'bubble'
193193
*/
194194
private getEventPath(responder: Observable, path: 'capture' | 'bubble'): Observable[] {
195-
recycledEventPath.splice(0, recycledEventPath.length);
196-
recycledEventPath.push(responder);
195+
recycledEventPath.splice(0, recycledEventPath.length, responder);
197196

198197
if (!responder.isViewBase()) {
199198
return recycledEventPath;

0 commit comments

Comments
 (0)