Fix editing missing apps.

git-svn-id: https://www.unprompted.com/svn/projects/tildefriends/trunk@3850 ed5197a5-7fde-0310-b194-c3ffbd925b24
This commit is contained in:
Cory McWilliams 2022-02-27 02:35:51 +00:00
parent c138582638
commit 07a87ff9de

View File

@ -204,8 +204,12 @@ function loadFile(name, id) {
function load(path) {
return fetch((path || url()) + 'view').then(function(response) {
if (!response.ok) {
if (response.status == 404) {
return null;
} else {
throw new Error(response.status + ' ' + response.statusText);
}
}
return response.json();
}).then(function(json) {
if (!gEditor) {