morley-upgradeable-0.3: Upgradeability infrastructure based on Morley.
Safe HaskellNone
LanguageHaskell2010

Lorentz.Contracts.UserUpgradeable.Migrations

Description

This module contains common functions and types related to user-defined upgrades. It intentionally does not include mint- and burn-related functionality because these should be handled by particular token implementations (V2 and V1 correspondingly).

Note that the naming in this module is different from Lorentz.Contracts.Upgradeable: by "migration" here we mean the process of transferring the value from an old contract to the new one rather than applying a transformation to storage.

Synopsis

Documentation

callMigrationTarget :: forall storage. HasMigrationTarget storage => '[Natural, storage] :-> '[([Operation], storage)] Source #

Forges a call to the new version; the forged operation contans the address of the sender, and the amount of tokens to mint.

initiateMigration :: forall storage. (HasAdmin storage, HasMigrationTarget storage) => '[MigrationTarget, storage] :-> '[([Operation], storage)] Source #

Starts a migration from an old version of a contract to a new one.

Orphan instances