Skip to content

Commit

Permalink
fix(store): resolveUserTypes for static arrays (#1876)
Browse files Browse the repository at this point in the history
Co-authored-by: Kevin Ingersoll <kingersoll@gmail.com>
  • Loading branch information
dk1a and holic committed Nov 7, 2023
1 parent 120863e commit bb91eda
Show file tree
Hide file tree
Showing 7 changed files with 517 additions and 2 deletions.
5 changes: 5 additions & 0 deletions .changeset/plenty-rules-pull.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@latticexyz/schema-type": minor
---

Added `isSchemaAbiType` helper function to check and narrow an unknown string to the `SchemaAbiType` type
6 changes: 6 additions & 0 deletions .changeset/sixty-crabs-itch.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"@latticexyz/store": patch
---

Fixed `resolveUserTypes` for static arrays.
`resolveUserTypes` is used by `deploy`, which prevented deploying tables with static arrays.
4 changes: 4 additions & 0 deletions e2e/packages/contracts/mud.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -47,5 +47,9 @@ export default mudConfig({
player: "address",
},
},
StaticArray: {
keySchema: {},
valueSchema: "uint256[2]",
},
},
});
1 change: 1 addition & 0 deletions e2e/packages/contracts/src/codegen/index.sol

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit bb91eda

Please sign in to comment.