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 crash when crafting callbacks return strings #12685

Merged
merged 1 commit into from
Aug 12, 2022

Conversation

Zughy
Copy link
Member

@Zughy Zughy commented Aug 10, 2022

Fixes #4947

To do

This PR is Ready for Review.

How to test

  • add:
minetest.register_on_craft(function(itemstack, player, old_craft_grid, craft_inv)
    return "default:wood"
end)
  • craft whatever. No crash (MTG needed)

@Zughy Zughy added @ Script API Bugfix 🐛 PRs that fix a bug labels Aug 10, 2022
Copy link
Member

@sfan5 sfan5 left a comment

Choose a reason for hiding this comment

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

Looks correct

@rubenwardy rubenwardy changed the title Fix crash when crafting callbacks return strings instead of ItemStacks Fix crash when crafting callbacks return strings Aug 12, 2022
@rubenwardy rubenwardy merged commit 8bf1609 into minetest:master Aug 12, 2022
sfan5 pushed a commit that referenced this pull request Sep 14, 2022
@Zughy Zughy deleted the itemstack branch July 31, 2023 13:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Inconsistent data types in Itemstack
3 participants