Skip to content

Commit 4fea7f5

Browse files
committed
DataManager.pop would emit the DataManager instance, instead of the parent, as the first event argument. It now emits the parent as it should do. Fix phaserjs#4186
1 parent fac2efe commit 4fea7f5

2 files changed

Lines changed: 2 additions & 1 deletion

File tree

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -377,6 +377,7 @@ one set of bindings ever created, which makes things a lot cleaner.
377377
* The WebGLRenderer will now apply a transparent background if `transparent = true` in the game config (thanks @gomachan7)
378378
* `List.sort` was missing the scope required for the sort handler, this is now correctly provided internally. Fix #4241 (thanks @jcyuan)
379379
* `Container.sort` was missing the scope required for the sort handler, this is now correctly provided internally. Fix #4241 (thanks @jcyuan)
380+
* `DataManager.pop` would emit the DataManager instance, instead of the parent, as the first event argument. It now emits the parent as it should do. Fix #4186 (thanks @gadelan)
380381

381382
### Examples and TypeScript
382383

src/data/DataManager.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -502,7 +502,7 @@ var DataManager = new Class({
502502
delete this.list[key];
503503
delete this.values[key];
504504

505-
this.events.emit(Events.REMOVE_DATA, this, key, data);
505+
this.events.emit(Events.REMOVE_DATA, this.parent, key, data);
506506
}
507507

508508
return data;

0 commit comments

Comments
 (0)