@takisvc/code-canvas 0.1.1 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -227,7 +227,7 @@ async function generateImage(endpoint2, prompt2, account2) {
227
227
  console.log();
228
228
  console.log(chalk.dim(`Server: ${errorBody.error}`));
229
229
  }
230
- return false;
230
+ return "needs-registration";
231
231
  } finally {
232
232
  clearInterval(interval);
233
233
  }
@@ -244,5 +244,5 @@ if (!prompt) {
244
244
  }
245
245
  var account = ensureWallet();
246
246
  var endpoint = `${SERVER_URL}/code-canvas/generate-image`;
247
- var success = await generateImage(endpoint, prompt, account);
248
- process.exit(success ? 0 : 1);
247
+ var result = await generateImage(endpoint, prompt, account);
248
+ process.exit(result === true ? 0 : result === "needs-registration" ? 0 : 1);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@takisvc/code-canvas",
3
- "version": "0.1.1",
3
+ "version": "0.1.2",
4
4
  "type": "module",
5
5
  "bin": {
6
6
  "code-canvas": "./dist/code-canvas.js"