Преглед на файлове

Add "text/plain" header

Anton преди 10 години
родител
ревизия
ef18900902
променени са 1 файла, в които са добавени 1 реда и са изтрити 0 реда
  1. 1 0
      Sources/HttpResponse.swift

+ 1 - 0
Sources/HttpResponse.swift

@@ -113,6 +113,7 @@ public enum HttpResponse {
             }
         case .OK(let body):
             switch body {
+            case .Text(_)   : headers["Content-Type"] = "text/plain"
             case .Json(_)   : headers["Content-Type"] = "application/json"
             case .Html(_)   : headers["Content-Type"] = "text/html"
             default:break