figma-api-stub
Advanced tools
Comparing version 0.0.7 to 0.0.8
@@ -30,2 +30,8 @@ "use strict"; | ||
} | ||
if (joinedConfig.simulateErrors && | ||
// @ts-ignore | ||
this.type === "DOCUMENT" && | ||
item.type !== "PAGE") { | ||
throw new Error("Error: The root node cannot have children of type other than PAGE"); | ||
} | ||
item.parent = this; | ||
@@ -42,2 +48,8 @@ this.children.push(item); | ||
} | ||
if (joinedConfig.simulateErrors && | ||
// @ts-ignore | ||
this.type === "DOCUMENT" && | ||
child.type !== "PAGE") { | ||
throw new Error("Error: The root node cannot have children of type other than PAGE"); | ||
} | ||
if (child.parent) { | ||
@@ -44,0 +56,0 @@ child.parent.children = child.parent.children.filter(function (_child) { return child !== _child; }); |
{ | ||
"name": "figma-api-stub", | ||
"version": "0.0.7", | ||
"version": "0.0.8", | ||
"description": "Figma API stub", | ||
@@ -5,0 +5,0 @@ "main": "./dist/index.js", |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
34275
810