Преглед изворни кода

Add defensive check for empty repository key

Brian Clozel пре 8 година
родитељ
комит
b2be58e5da
1 измењених фајлова са 1 додато и 1 уклоњено
  1. 1 1
      js/projectDocumentationWidget.js

+ 1 - 1
js/projectDocumentationWidget.js

@@ -95,7 +95,7 @@ Spring.SnippetView = Backbone.View.extend({
     this.combinedTemplate = _.template(
     	"<div class=\"highlight\"><pre><code>" +
         downloadTemplate.find("code:first").html() +
-        "{@ if (repository) { @}" +
+        "{@ if (typeof(repository) != \"undefined\") { @}" +
         repositoryTemplate.find("code:first").html() +
         "{@ } @}" +
         "</code></pre></div>"