UNPKG

hardhat

Version:

Hardhat is an extensible developer tool that helps smart contract developers increase productivity by reliably bringing together the tools they want.

19 lines (17 loc) 391 B
import { TaskIdentifier } from "../../../types"; export function parseTaskIdentifier(taskIdentifier: TaskIdentifier): { scope: string | undefined; task: string; } { if (typeof taskIdentifier === "string") { return { scope: undefined, task: taskIdentifier, }; } else { return { scope: taskIdentifier.scope, task: taskIdentifier.task, }; } }