diff options
author | suelockwood <deathbearbrown@gmail.com> | 2013-09-18 16:13:06 -0400 |
---|---|---|
committer | Garren Smith <garren.smith@gmail.com> | 2013-09-19 14:50:52 +0200 |
commit | d719b781fba6f2f9cb90d55b2dd741c859124455 (patch) | |
tree | 83caaf7756918fc18e0d95df8a09b25c21203cd0 | |
parent | e9bddf967c9a92a56e3e99d3fa2be40705f0c428 (diff) | |
download | couchdb-d719b781fba6f2f9cb90d55b2dd741c859124455.tar.gz |
Added clear:true to the notification for when a document doesn't exist so that it overwrites the generic error messaging
-rw-r--r-- | src/fauxton/app/api.js | 2 | ||||
-rw-r--r-- | src/fauxton/app/modules/documents/views.js | 3 |
2 files changed, 3 insertions, 2 deletions
diff --git a/src/fauxton/app/api.js b/src/fauxton/app/api.js index 192678eea..9c2b523c0 100644 --- a/src/fauxton/app/api.js +++ b/src/fauxton/app/api.js @@ -358,7 +358,7 @@ function(app, Fauxton) { }.bind(this), function (resp) { if (!resp) { return; } FauxtonAPI.addNotification({ - msg: 'An Error occurred' + resp.responseText, + msg: 'An Error occurred' + JSON.parse(resp.responseText).reason, type: 'error' }); }); diff --git a/src/fauxton/app/modules/documents/views.js b/src/fauxton/app/modules/documents/views.js index d66c6da7c..09ef2b5a1 100644 --- a/src/fauxton/app/modules/documents/views.js +++ b/src/fauxton/app/modules/documents/views.js @@ -656,7 +656,8 @@ function(app, FauxtonAPI, Components, Documents, pouchdb, Codemirror, JSHint, re if (xhr.status === 404) { FauxtonAPI.addNotification({ msg: 'The document does not exist', - type: 'error' + type: 'error', + clear: true }); FauxtonAPI.navigate('/database/' + databaseId + '/_all_docs?limit=20'); } |