Commit Graph

2 Commits

Author SHA1 Message Date
Tyera Eulberg c00adbe3a7
Add capability to freeze token Accounts (#297)
* Add freeze elements to state structs

* Add can_freeze paramter to InitializeMint instruction, and plumb

* Add fixed_supply parameter to InitializeMint

* Convert to SetAuthority instruction

* Add frozen restrictions

* Add FreezeAccount instruction

* Make FreezeAccount into toggle

* Add parameter to make freezing explicit

* Pass mint owner, freeze_authority as parameters

* Rename ToggleFreeze

* Make AuthorityType more explicit

* Rename mint owner => mint_authority

* Add Account::is_frozen method

* C header updates

* s/is_initialized/state for Account

* Minting nit

* Add helpers to clean up AuthorityType packing

* Split FreezeAccount into 2 instructions

* Pass new_authority as parameter not account

* More C header updates

* Use new COption helpers

* Use boolean for toggle fn
2020-08-25 14:24:11 -06:00
Michael Vines e440466311 Add token program2 2020-08-14 22:50:18 +00:00