Skip to content

Commit fe0f7ed

Browse files
rafaelss95jelbourn
authored andcommitted
refactor: use emit instead of next for event emitters (#9610)
1 parent 0f2ac9b commit fe0f7ed

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/lib/paginator/paginator.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ export class MatPaginator implements OnInit, OnDestroy {
190190

191191
/** Emits an event notifying that a change of the paginator's properties has been triggered. */
192192
private _emitPageEvent() {
193-
this.page.next({
193+
this.page.emit({
194194
pageIndex: this.pageIndex,
195195
pageSize: this.pageSize,
196196
length: this.length

src/lib/sort/sort.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ export class MatSort extends _MatSortMixinBase implements CanDisable, OnChanges,
128128
this.direction = this.getNextSortDirection(sortable);
129129
}
130130

131-
this.sortChange.next({active: this.active, direction: this.direction});
131+
this.sortChange.emit({active: this.active, direction: this.direction});
132132
}
133133

134134
/** Returns the next sort direction of the active sortable, checking for potential overrides. */

0 commit comments

Comments
 (0)