CheckAndJumpToNonFundedFacet
Connector facet for transitioning campaigns to the NON_FUNDED state when applicable.
_This facet is used by TMI-Fraction Platforms that support campaigns capable of reaching the NON_FUNDED state.
It serves as a switch, transitioning a campaign's state from PURCHASE to NON_FUNDED if the required conditions
are met (e.g., failure to reach the softcap during the purchase phase).
IMPORTANT:
- This implementation does not enforce any access control or gating for callers of
checkAndJumpToNonFundedfunction.
NOTE:
- Connectors intervene at predetermined intermediate state(s) and progress campaigns to predetermined destination state(s).
- This connector is designed to intervene at the
PURCHASEstate only and transition to theNON_FUNDEDstate. - This connector should only be utilized by Platforms that support campaigns capable of reaching a
NON_FUNDEDstate._
UnauthorizedInitialization
Thrown when trying to initialize from non admin account.
PurchaseToNonFundedConnectorInitialized
Emitted at initPurchaseToNonFundedConnector().
CheckedAndJumpedToNonFunded
Emitted at checkAndJumpToNonFunded().
initPurchaseToNonFundedConnector
Initializes the CheckAndJumpToNonFundedFacetStorage by registering the intermediate state (PURCHASE) and
the destination state (STATE) for this connector.
_Campaign states in a TMI-Fraction Platform are represented as uint256 values and are configured during the
initialization of the generic StateFacet (see StateFacet.sol). Extra care should be taken to ensure consistency
with the value schema used for the states, as defined in the StateFacet configuration (e.g., using enums).
Emits a {PurchaseToNonFundedConnectorInitialized} event.
This function can only be called by the Admin (see AccessControlFacet.sol)._
Parameters
| Name | Type | Description |
|---|---|---|
| initPurchaseToNonFundedData | bytes | The ABI-encoded data containing: - intermediateState: uint256 representing the PURCHASE state for any campaign. - destinationState: uint256 representing the NON_FUNDED state for any campaign. |
checkAndJumpToNonFunded
Transitions the specified campaign from its PURCHASE state to its NON_FUNDED state if the required
conditions are met (i.e., the campaign failed to raise adequate funds within the designated time).
_This function can be called by any address, but can only be executed if the current state of
campaignId is PURCHASE and the purchase phase time window has elapsed without meeting the
campaign's funding target.
Emits a {CheckedAndJumpedToNonFunded} event._
Parameters
| Name | Type | Description |
|---|---|---|
| campaignId | uint256 | The unique identifier of the targeted campaign. |

