aboutsummaryrefslogtreecommitdiff
path: root/juick-api/src/main/java/com/juick/api/Main.java
diff options
context:
space:
mode:
authorGravatar Vitaly Takmazov2016-07-11 12:25:03 +0300
committerGravatar Vitaly Takmazov2016-07-11 12:25:03 +0300
commitd6fb4288688294d2f76325f14410db3091fea0fa (patch)
treed2070a67794644c2602eaf5bcc41e10438c62f89 /juick-api/src/main/java/com/juick/api/Main.java
parent3d0ec22f5262058a08e7f551eb5ac02e3636008a (diff)
logging
Diffstat (limited to 'juick-api/src/main/java/com/juick/api/Main.java')
-rw-r--r--juick-api/src/main/java/com/juick/api/Main.java8
1 files changed, 4 insertions, 4 deletions
diff --git a/juick-api/src/main/java/com/juick/api/Main.java b/juick-api/src/main/java/com/juick/api/Main.java
index afd7c11c..03c97435 100644
--- a/juick-api/src/main/java/com/juick/api/Main.java
+++ b/juick-api/src/main/java/com/juick/api/Main.java
@@ -253,7 +253,7 @@ public class Main extends HttpServlet implements Stream.StreamListener {
try {
attachmentFName = Utils.receiveMultiPartFile(request, "attach");
} catch (Exception e) {
- System.out.println("MULTIPART ERROR: " + e.toString());
+ log("MULTIPART ERROR", e);
response.sendError(400);
return;
}
@@ -264,7 +264,7 @@ public class Main extends HttpServlet implements Stream.StreamListener {
URL imgUrl = new URL(paramImg);
attachmentFName = Utils.downloadImage(imgUrl);
} catch (Exception e) {
- System.out.println("DOWNLOAD ERROR: " + e.toString());
+ log("DOWNLOAD ERROR", e);
response.sendError(500);
return;
}
@@ -369,7 +369,7 @@ public class Main extends HttpServlet implements Stream.StreamListener {
try {
attachmentFName = Utils.receiveMultiPartFile(request, "attach");
} catch (Exception e) {
- System.out.println("MULTIPART ERROR: " + e.toString());
+ log("MULTIPART ERROR", e);
response.sendError(400);
return;
}
@@ -379,7 +379,7 @@ public class Main extends HttpServlet implements Stream.StreamListener {
try {
attachmentFName = Utils.downloadImage(new URL(paramImg));
} catch (Exception e) {
- System.out.println("DOWNLOAD ERROR: " + e.toString());
+ log("DOWNLOAD ERROR", e);
response.sendError(500);
return;
}