Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing undefined return type for CostMatrix#get #216

Open
Jomik opened this issue Sep 11, 2022 · 0 comments
Open

Missing undefined return type for CostMatrix#get #216

Jomik opened this issue Sep 11, 2022 · 0 comments
Labels
bug good first issue Good for newcomers

Comments

@Jomik
Copy link
Contributor

Jomik commented Sep 11, 2022

Expected Behavior

Correct typing for CostMatrix#get, it can return undefined.

Actual Behavior

CostMatrix#get returns undefined if input is out of bounds.

Sample code (if available)

const costMatrix = new PathFinder.CostMatrix();
costMatrix.get(-1, 0) == undefined; // true

Your Environment

  • Node.js version: 16
  • TypeScript version: 4.6.3
  • @types/screeps version: 3.3.0
@Jomik Jomik added the bug label Sep 11, 2022
@DiamondMofeng DiamondMofeng added the non-breaking change A non-breaking feature would be introduced label Feb 26, 2023
@DiamondMofeng DiamondMofeng added the good first issue Good for newcomers label Aug 23, 2023
@DiamondMofeng DiamondMofeng removed the non-breaking change A non-breaking feature would be introduced label Sep 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

2 participants