Skip to content

Error: GetLast function not implemented correctly #6513

@dmokel

Description

@dmokel

Version

  • Phaser Version: v3.60.0
  • Operating system: macOS Monterey
  • Browser: Chrome

Description

From a semantic perspective, the GetFirst method returns the first element in the array that has properties which match all of those specified in the compare object and the GetLast method returns the last element in the array that has properties which match all of those specified in the compare object. But their source codes are the same now.

The GetLast function code is incorrect.
image
image

Example Test Code

Additional Information

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions