Browse Source

Merge pull request #382 from lwzm/fix-swagger-json-format

Escape control-characters in generated swagger
Maurits van der Schee 7 years ago
parent
commit
2637fd8f92
No account linked to committer's email address
1 changed files with 1 additions and 1 deletions
  1. 1
    1
      api.php

+ 1
- 1
api.php View File

@@ -2367,7 +2367,7 @@ class PHP_CRUD_API {
2367 2367
 			if ($i>0) echo ',';
2368 2368
 			echo '{';
2369 2369
 			echo '"name":"'.$table['name'].'",';
2370
-			echo '"description":"'.$table['comments'].'"';
2370
+			echo '"description":'.json_encode($table['comments']);
2371 2371
 			echo '}';
2372 2372
 		}
2373 2373
 		echo '],';

Loading…
Cancel
Save