Joystream / joystream

Joystream Monorepo
http://www.joystream.org
GNU General Public License v3.0
1.42k stars 115 forks source link

Implement mapping for `UpdateGlobalNftLimit` proposal type #4853

Closed zeeshanakram3 closed 1 year ago

zeeshanakram3 commented 1 year ago

Context

Discovered while working on #4842

In the ProposalCreated mappings, the condition for checking proposalDetails.type === "UpdateGlobalNftLimit" does not exist. And since the ProposalCreated mappings throw an error for unimplemented/unsupported proposal types, this mapping would throw an exception when the UpdateGlobalNftLimit proposal type is unfiltered (in future runtime upgrade) and a proposal is created of this type.

https://github.com/Joystream/joystream/blob/d1448236349154afa2c1a725f7144990c37d5042/query-node/mappings/src/proposals.ts#L306

Fix

Handle the UpdateGlobalNftLimit proposal type in the mapping