From 23f445c66b96c074c8ca430300ffab599e3eb6ee Mon Sep 17 00:00:00 2001 From: Yuval Adam Date: Fri, 18 May 2012 12:42:31 +0300 Subject: default alpha param fix --- lsys.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lsys.js b/lsys.js index 8f7ec49..b102107 100644 --- a/lsys.js +++ b/lsys.js @@ -13,8 +13,9 @@ function LSystem(axiom, rules) { }; this.draw = function(alpha) { - if (alpha === undefined) + if (!alpha) { alpha = 90 * (Math.PI / 180); + } var coords = []; var stack = []; -- cgit v1.3.1