Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use the provided
caller
instead of Location::caller()
in `despawn…
…_with_caller()` (#17598) # Objective Pass the correct location to triggers when despawning entities. `EntityWorldMut::despawn_with_caller()` currently passes `Location::caller()` to some triggers instead of the `caller` parameter it was passed. As `despawn_with_caller()` is not `#[track_caller]`, this means the location will always be reported as `despawn_with_caller()` itself. ## Solution Pass `caller` instead of `Location::caller()`.
- Loading branch information