{"action":"closed","issue":{"url":"https://api.github.com/repos/takkaria/echojs/issues/97","labels_url":"https://api.github.com/repos/takkaria/echojs/issues/97/labels{/name}","comments_url":"https://api.github.com/repos/takkaria/echojs/issues/97/comments","events_url":"https://api.github.com/repos/takkaria/echojs/issues/97/events","html_url":"https://github.com/takkaria/echojs/issues/97","id":103073774,"number":97,"title":"\"Can't set errors after they are sent\" error","user":{"login":"takkaria","id":405490,"avatar_url":"https://avatars.githubusercontent.com/u/405490?v=3","gravatar_id":"","url":"https://api.github.com/users/takkaria","html_url":"https://github.com/takkaria","followers_url":"https://api.github.com/users/takkaria/followers","following_url":"https://api.github.com/users/takkaria/following{/other_user}","gists_url":"https://api.github.com/users/takkaria/gists{/gist_id}","starred_url":"https://api.github.com/users/takkaria/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/takkaria/subscriptions","organizations_url":"https://api.github.com/users/takkaria/orgs","repos_url":"https://api.github.com/users/takkaria/repos","events_url":"https://api.github.com/users/takkaria/events{/privacy}","received_events_url":"https://api.github.com/users/takkaria/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/takkaria/echojs/milestones/1","html_url":"https://github.com/takkaria/echojs/milestones/0.1.0","labels_url":"https://api.github.com/repos/takkaria/echojs/milestones/1/labels","id":1152818,"number":1,"title":"0.1.0","description":"Our first production release, hurrah.","creator":{"login":"takkaria","id":405490,"avatar_url":"https://avatars.githubusercontent.com/u/405490?v=3","gravatar_id":"","url":"https://api.github.com/users/takkaria","html_url":"https://github.com/takkaria","followers_url":"https://api.github.com/users/takkaria/followers","following_url":"https://api.github.com/users/takkaria/following{/other_user}","gists_url":"https://api.github.com/users/takkaria/gists{/gist_id}","starred_url":"https://api.github.com/users/takkaria/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/takkaria/subscriptions","organizations_url":"https://api.github.com/users/takkaria/orgs","repos_url":"https://api.github.com/users/takkaria/repos","events_url":"https://api.github.com/users/takkaria/events{/privacy}","received_events_url":"https://api.github.com/users/takkaria/received_events","type":"User","site_admin":false},"open_issues":10,"closed_issues":5,"state":"open","created_at":"2015-06-06T16:44:26Z","updated_at":"2015-10-03T20:19:00Z","due_on":null,"closed_at":null},"comments":1,"created_at":"2015-08-25T17:09:57Z","updated_at":"2015-10-03T20:19:00Z","closed_at":"2015-10-03T20:19:00Z","body":"Keep on getting echojs falling over due to this error:\r\n\r\n```\r\n00:49:20 web.2 |  http.js:690\r\n00:49:20 web.2 |  throw new Error('Can\\'t set headers after they are sent.'…\r\n00:49:20 web.2 |  ^\r\n00:49:29 web.2 |  Error: Can't set headers after they are sent.\r\n00:49:29 web.2 |  at ServerResponse.OutgoingMessage.setHeader (http.js:690:…\r\n00:49:29 web.2 |  at ServerResponse.header (/var/www/echomanchester.net/ech…\r\n00:49:29 web.2 |  at ServerResponse.send (/var/www/echomanchester.net/echoj…\r\n00:49:29 web.2 |  at fn (/var/www/echomanchester.net/echojs/node_modules/ex…\r\n00:49:29 web.2 |  at /var/www/echomanchester.net/echojs/node_modules/swig/l…\r\n00:49:29 web.2 |  at /var/www/echomanchester.net/echojs/node_modules/swig/l…\r\n00:49:29 web.2 |  at fs.js:272:14\r\n00:49:29 web.2 |  at Object.oncomplete (fs.js:108:15)\r\n```\r\n\r\nSome digging suggests there may be times when we call response.end() twice.  This might be a pain to track down.  Some info: https://stackoverflow.com/questions/26307920/res-json-cant-set-headers-after-they-are-sent"}}