summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--dozentenmodulserver/src/main/java/org/openslx/bwlp/sat/fileserv/FileServer.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/dozentenmodulserver/src/main/java/org/openslx/bwlp/sat/fileserv/FileServer.java b/dozentenmodulserver/src/main/java/org/openslx/bwlp/sat/fileserv/FileServer.java
index 0d283848..597e4306 100644
--- a/dozentenmodulserver/src/main/java/org/openslx/bwlp/sat/fileserv/FileServer.java
+++ b/dozentenmodulserver/src/main/java/org/openslx/bwlp/sat/fileserv/FileServer.java
@@ -84,7 +84,7 @@ public class FileServer implements IncomingEvent {
@Override
public void incomingDownloadRequest(Uploader uploader) throws IOException {
String token = uploader.getToken();
- OutgoingDataTransfer download = downloads.get(token);
+ OutgoingDataTransfer download = token == null ? null : downloads.get(token);
if (download == null) {
LOGGER.warn("Download request: Unknown token " + token);
uploader.cancel();
@@ -98,7 +98,7 @@ public class FileServer implements IncomingEvent {
@Override
public void incomingUploadRequest(Downloader downloader) throws IOException {
String token = downloader.getToken();
- IncomingDataTransfer upload = uploads.get(token);
+ IncomingDataTransfer upload = token == null ? null : uploads.get(token);
if (upload == null) {
LOGGER.warn("Upload request: Unknown token " + token);
downloader.cancel();