|
@@ -86,7 +86,10 @@ function switchWalker (switchCommand) {
|
|
|
* @param {Commands.Return} returnCommand
|
|
|
* */
|
|
|
function returnWalker (returnCommand) {
|
|
|
- const expression = expressionWalker(returnCommand.expression);
|
|
|
+ let expression = null;
|
|
|
+ if (returnCommand.expression !== null) {
|
|
|
+ expression = expressionWalker(returnCommand.expression);
|
|
|
+ }
|
|
|
return {
|
|
|
type: "return",
|
|
|
expression,
|