function conditionalReturn<T>(condition, value): Promise<undefined | T>;Defined in: aa-sdk/core/src/utils/index.ts:152
Utility method for checking the condition and return the value if condition holds true, undefined if not.
| Type Parameter |
|---|
|
| Parameter | Type | Description |
|---|---|---|
|
| condition to check |
| () => | value to return when condition holds true |
Promise<undefined | T>
the value if condition holds true, undefined if not