Commit 415bc507 authored by Leo Iannacone's avatar Leo Iannacone

handling error messages as string

parent 8acef892
......@@ -109,8 +109,12 @@ watch_path_onsocket = (event_name, socket, data, watch_path, callback) ->
errors_handler = (from, err, socket) ->
from = "NO SOCKET: " + from unless socket
console.error from, err.message
socket.emit config.events.error, err.message if socket
if err.message?
msg = err.message
else
msg = err
console.error from, msg
socket.emit config.events.error, message if socket
return
Tail::watchEvent = (e) ->
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment