summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjmoenig <jens@moenig.org>2015-01-13 08:36:41 +0100
committerjmoenig <jens@moenig.org>2015-01-13 08:36:41 +0100
commit14821611faf72b86c886eb10d221f0ed550bb7e7 (patch)
treea4aa8e1a8220a462b470bf094a91c25eab3875cb
parent667193b9f02331b3372fefbb9fd4a424d5b86d7e (diff)
downloadsnap-byow-14821611faf72b86c886eb10d221f0ed550bb7e7.tar.gz
snap-byow-14821611faf72b86c886eb10d221f0ed550bb7e7.zip
fixed #702
-rw-r--r--byob.js18
1 files changed, 10 insertions, 8 deletions
diff --git a/byob.js b/byob.js
index b5905ce..9e7dfc8 100644
--- a/byob.js
+++ b/byob.js
@@ -9,7 +9,7 @@
written by Jens Mönig
jens@moenig.org
- Copyright (C) 2014 by Jens Mönig
+ Copyright (C) 2015 by Jens Mönig
This file is part of Snap!.
@@ -106,7 +106,7 @@ SymbolMorph, isNil*/
// Global stuff ////////////////////////////////////////////////////////
-modules.byob = '2014-November-20';
+modules.byob = '2015-January-13';
// Declarations
@@ -209,12 +209,14 @@ CustomBlockDefinition.prototype.copyAndBindTo = function (sprite) {
c.receiver = sprite; // only for (kludgy) serialization
c.declarations = copy(this.declarations); // might have to go deeper
- c.body = Process.prototype.reify.call(
- null,
- this.body.expression,
- new List(this.inputNames())
- );
- c.body.outerContext = null;
+ if (c.body) {
+ c.body = Process.prototype.reify.call(
+ null,
+ this.body.expression,
+ new List(this.inputNames())
+ );
+ c.body.outerContext = null;
+ }
return c;
};