Skip to content
This repository has been archived by the owner on Nov 8, 2024. It is now read-only.

Commit

Permalink
add debug support
Browse files Browse the repository at this point in the history
  • Loading branch information
kuba-kubula committed Aug 26, 2014
1 parent 3f5f740 commit eb38d60
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/forkable.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ run = (msg) ->
unless script
error "No code to run"
return false
if msg?.context?.debug is true
msg.context.console = console
try
res =
result: script.runInNewContext(msg.context || {}) || null # script can return undefined, ensure it's null
Expand Down

0 comments on commit eb38d60

Please sign in to comment.