git://git.nikiroo.be
/
fanfix.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
code cleanup
[fanfix.git]
/
src
/
be
/
nikiroo
/
fanfix
/
library
/
WebLibraryServer.java
diff --git
a/src/be/nikiroo/fanfix/library/WebLibraryServer.java
b/src/be/nikiroo/fanfix/library/WebLibraryServer.java
index 22f36e91f5729a7bfef72fe9c98d2a7fa157a6ec..56d78ed4de20b5a52583af21105043a07cc8e89f 100644
(file)
--- a/
src/be/nikiroo/fanfix/library/WebLibraryServer.java
+++ b/
src/be/nikiroo/fanfix/library/WebLibraryServer.java
@@
-217,9
+217,8
@@
public class WebLibraryServer extends WebLibraryServerHtml {
jsons.add(JsonIO.toJson(meta));
}
jsons.add(JsonIO.toJson(meta));
}
- return newInputStreamResponse("application/json",
- new ByteArrayInputStream(
- new JSONArray(jsons).toString().getBytes()));
+ return NanoHTTPD.newFixedLengthResponse(Status.OK,
+ "application/json", new JSONArray(jsons).toString());
}
return NanoHTTPD.newFixedLengthResponse(Status.BAD_REQUEST,
}
return NanoHTTPD.newFixedLengthResponse(Status.BAD_REQUEST,