From 3f904b6a59307f9072822b118a328772121756c0 Mon Sep 17 00:00:00 2001 From: Fabian Homborg Date: Mon, 22 Jun 2020 19:50:51 +0200 Subject: [PATCH] webconfig: Replace unsafe binding with filter ng-bind-html-unsafe was apparently removed. --- share/tools/web_config/js/app.js | 7 +++++++ share/tools/web_config/partials/prompt.html | 4 ++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/share/tools/web_config/js/app.js b/share/tools/web_config/js/app.js index 4da1e143a..b602a8cd0 100644 --- a/share/tools/web_config/js/app.js +++ b/share/tools/web_config/js/app.js @@ -1,5 +1,12 @@ fishconfig = angular.module("fishconfig", ["filters", "controllers", "ngRoute", "ngSanitize"]); +angular.module('fishconfig') + .filter('to_trusted', ['$sce', function($sce){ + return function(text) { + return $sce.trustAsHtml(text); + }; + }]); + fishconfig.config( ["$routeProvider", function($routeProvider) { $routeProvider diff --git a/share/tools/web_config/partials/prompt.html b/share/tools/web_config/partials/prompt.html index 069a3d819..a1a37b0ba 100644 --- a/share/tools/web_config/partials/prompt.html +++ b/share/tools/web_config/partials/prompt.html @@ -1,7 +1,7 @@
{{ selectedPrompt.name }}
-
+
{{ prompt.name }}
-
+