From d53028098fff66bc06d938a8e9b6deac852c0034 Mon Sep 17 00:00:00 2001 From: Yosh de Vos Date: Fri, 8 Aug 2014 09:51:05 +0200 Subject: [PATCH] Fixed endpoint is undefined in sandbox when custom_endpoint is disabled --- Resources/views/layout.html.twig | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Resources/views/layout.html.twig b/Resources/views/layout.html.twig index a33a4ab..018bd18 100755 --- a/Resources/views/layout.html.twig +++ b/Resources/views/layout.html.twig @@ -396,9 +396,11 @@ {% else -%} var endpoint = '{{ endpoint }}'; {% endif -%} + {% if authentication.custom_endpoint %} if ($('#api_endpoint') && typeof($('#api_endpoint').val()) != 'undefined') { endpoint = $('#api_endpoint').val(); } + {% endif %} // Workaround for Firefox bug and a thereby resulting nginx incompatibility if (method == "LINK") {