diff --git a/gateway/assets/index.html b/gateway/assets/index.html index 739add10..8ac8dc48 100644 --- a/gateway/assets/index.html +++ b/gateway/assets/index.html @@ -158,8 +158,8 @@ Text - JSON - Download + JSON + Download diff --git a/gateway/assets/script/bootstrap.js b/gateway/assets/script/bootstrap.js index ede2affe..fdbd74fc 100644 --- a/gateway/assets/script/bootstrap.js +++ b/gateway/assets/script/bootstrap.js @@ -225,7 +225,11 @@ app.controller("home", ['$scope', '$log', '$http', '$location', '$interval', '$f $scope.invocationResponse = ""; $scope.invocationStatus = ""; $scope.invocationInProgress = false; - $scope.invocation.contentType = "text"; + if (fn.labels && fn.labels['com.openfaas.ui.ext']) { + $scope.invocation.contentType = "binary"; + } else { + $scope.invocation.contentType = "text"; + } $scope.invocation.roundTripDuration = ""; } };