From ffc04c0fee18352cfc7a11834262a7e37cf006dc Mon Sep 17 00:00:00 2001 From: Adam Bergmark Date: Mon, 18 Nov 2013 06:01:52 +0100 Subject: [PATCH] attempt at implementing automatic fayToJs case for actions, attempt 2 (faylang/fay-angular#4) --- js/runtime.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/js/runtime.js b/js/runtime.js index 5d9af67..343be65 100644 --- a/js/runtime.js +++ b/js/runtime.js @@ -240,6 +240,9 @@ function Fay$$fayToJs(type,fayObj){ else if(base == "automatic" && fayObj instanceof Function) { return Fay$$fayToJs(["function", "automatic_function"], fayObj); } + else if(base == "automatic" && fayObj instanceof Fay$$Monad) { + return Fay$$fayToJs(["automatic"],Fay$$_(fayObj,true).value); + } else if(base == "automatic" || base == "user") { fayObj = Fay$$_(fayObj);