From 8f237e1b375544836e8e4c9d5498b252bac42306 Mon Sep 17 00:00:00 2001 From: Mark Paluch Date: Fri, 24 Mar 2017 11:06:28 +0100 Subject: [PATCH] Add defensive check for empty repository key --- js/projectDocumentationWidget.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/projectDocumentationWidget.js b/js/projectDocumentationWidget.js index 2e30a3587..a52d9ba61 100644 --- a/js/projectDocumentationWidget.js +++ b/js/projectDocumentationWidget.js @@ -95,7 +95,7 @@ Spring.SnippetView = Backbone.View.extend({ this.combinedTemplate = _.template( "
" +
         downloadTemplate.find("code:first").html() +
-        "{@ if (repository) { @}" +
+        "{@ if (typeof(repository) != \"undefined\") { @}" +
         repositoryTemplate.find("code:first").html() +
         "{@ } @}" +
         "
"