Got questions, comments, patches, etc.?
Contact Jason Woofenden
gitweb
/
af-coffee.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(from parent 1:
f4eb811
)
json_request always pass response, even if empty
author
Jason Woofenden
<jason@jasonwoof.com>
Mon, 11 Feb 2013 21:50:39 +0000
(16:50 -0500)
committer
Jason Woofenden
<jason@jasonwoof.com>
Mon, 11 Feb 2013 22:18:15 +0000
(17:18 -0500)
api.coffee
patch
|
blob
|
history
diff --git
a/api.coffee
b/api.coffee
index
318531f
..
156e91c
100644
(file)
--- a/
api.coffee
+++ b/
api.coffee
@@
-142,8
+142,8
@@
json_request = (method, path, data, token, callback) ->
data = JSON.stringify data
request method, path, 'application/json', data, token, (err, response) ->
return callback err if err
- return callback() if response is ' '
- return callback() if response is ''
+ return callback null, '' if response is ' '
+ return callback null, '' if response is ''
try
callback null, JSON.parse(response)
catch error