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

Fix default value, filter input, metadata, relational variable, ternary incorrectly converting #3930

Merged

Conversation

TPGamesNL
Copy link
Member

Description

The expressions in the title were converting incorrectly, because they were only storing the supertype of the given classes to convert to, instead of the classes themselves. If the classes were, for example, ItemStack and ItemType, the stored supertype would be Object, which would match any returned object, e.g. InventorySlot, even if that class doesn't match the given types.


Target Minecraft Versions: any
Requirements: none
Related Issues: #3905

@TPGamesNL TPGamesNL added bug An issue that needs to be fixed. Alternatively, a PR fixing an issue. 2.5 labels Apr 27, 2021
Copy link
Member

@FranKusmiruk FranKusmiruk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice catch

@FranKusmiruk FranKusmiruk merged commit 31b11c8 into SkriptLang:master Apr 28, 2021
@TPGamesNL TPGamesNL deleted the fix/filter-input-conversion branch April 28, 2021 08:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug An issue that needs to be fixed. Alternatively, a PR fixing an issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants