onflow / nft-catalog

https://www.flow-nft-catalog.com/
The Unlicense
37 stars 13 forks source link

Use Authorization to store proposer's address #5

Closed bshahid331 closed 2 years ago

bshahid331 commented 2 years ago

Summary

We want to store the account that is making a proposal to the catalog. In order to prove a user owns an address and the we use an auth model that involves the user authorizing and update to a managed resource. This diff includes..

  1. New Proposal Manager resource used for authz
  2. Use manager to validate address and store address in NFTCatalog proposals.
  3. Add ability for proposer to withdraw a proposal.(leverages new authz method)
  4. Updates to propose cadence transaction
  5. Withdraw cadence transaction

Test Plan Added new test case for withdraw and confirmed old test cases still pass. Tried withdrawing from a separate account, as well.