@newos/cli
Version:
Command-line interface for the NewOS
18 lines • 681 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.parseContractReference = void 0;
const naming_1 = require("./naming");
function parseContractReference(contractReference) {
let proxyAddress;
let contractName;
let packageName;
if (contractReference && contractReference.startsWith('0x')) {
proxyAddress = contractReference;
}
else if (contractReference) {
({ contractName, package: packageName } = naming_1.fromContractFullName(contractReference));
}
return { proxyAddress, contractName, packageName };
}
exports.parseContractReference = parseContractReference;
//# sourceMappingURL=contract.js.map