Procházet zdrojové kódy

undid double stringify

bubble
Tony Tam před 10 roky
rodič
revize
a39ab425bf
3 změnil soubory, kde provedl 3 přidání a 3 odebrání
  1. +1
    -1
      dist/swagger-ui.js
  2. +1
    -1
      dist/swagger-ui.min.js
  3. +1
    -1
      src/main/coffeescript/view/OperationView.coffee

+ 1
- 1
dist/swagger-ui.js Zobrazit soubor

@@ -2096,7 +2096,7 @@ helpers = this.merge(helpers, Handlebars.helpers); data = data || {};
} else if (contentType === "application/json" || /\+json$/.test(contentType)) {
json = null;
try {
json = JSON.stringify(JSON.stringify(JSON.parse(content), null, " "));
json = JSON.stringify(JSON.parse(content), null, " ");
} catch (_error) {
e = _error;
json = "can't parse JSON. Raw result:\n\n" + content;


+ 1
- 1
dist/swagger-ui.min.js
Diff nebyl zobrazen, protože je příliš veliký
Zobrazit soubor


+ 1
- 1
src/main/coffeescript/view/OperationView.coffee Zobrazit soubor

@@ -368,7 +368,7 @@ class OperationView extends Backbone.View
else if contentType is "application/json" || /\+json$/.test(contentType)
json = null
try
json = JSON.stringify(JSON.stringify(JSON.parse(content), null, " "))
json = JSON.stringify(JSON.parse(content), null, " ")
catch e
json = "can't parse JSON. Raw result:\n\n" + content
code = $('<code />').text(json)


Načítá se…
Zrušit
Uložit