diff --git a/DulcificumJS/package.json b/DulcificumJS/package.json index b1e0ca2..0bbefba 100644 --- a/DulcificumJS/package.json +++ b/DulcificumJS/package.json @@ -1,6 +1,6 @@ { "name": "@ultimaker/dulcificumjs", - "version": "0.1.0-alpha.6", + "version": "0.1.0-alpha.7", "description": "DulcificumJS is a TS component to run Dulcificum in a browser", "main": "dist/index.js", "scripts": { diff --git a/DulcificumJS/src/index.ts b/DulcificumJS/src/index.ts index 5197bd4..01ca2a9 100644 --- a/DulcificumJS/src/index.ts +++ b/DulcificumJS/src/index.ts @@ -13,5 +13,8 @@ export async function initialize(): Promise { } export function gcode_2_miracle_jtp(input: string): string { + if (mod == null) { + return ""; + } return mod.gcode_2_miracle_jtp(input); }