From 933df31a8a40183b03a79a9f5c786b4c4ca3a1c6 Mon Sep 17 00:00:00 2001 From: ulrich Date: Sun, 11 Apr 2021 16:03:44 +0000 Subject: [PATCH] Hauptmenue aktualisiert --- src/de/uhilger/mediaz/api/AbstractHandler.java | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/src/de/uhilger/mediaz/api/AbstractHandler.java b/src/de/uhilger/mediaz/api/AbstractHandler.java index 728107a..af0ba5b 100644 --- a/src/de/uhilger/mediaz/api/AbstractHandler.java +++ b/src/de/uhilger/mediaz/api/AbstractHandler.java @@ -17,6 +17,7 @@ */ package de.uhilger.mediaz.api; +import com.sun.net.httpserver.Headers; import com.sun.net.httpserver.HttpExchange; import com.sun.net.httpserver.HttpHandler; import java.io.BufferedReader; @@ -90,6 +91,8 @@ break; } logger.fine(response); + Headers headers = e.getResponseHeaders(); + headers.add("Content-Type", "application/json"); e.sendResponseHeaders(getReturnCode(), response.length()); OutputStream os = e.getResponseBody(); os.write(response.getBytes()); -- Gitblit v1.9.3