You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@couchdb.apache.org by me...@apache.org on 2013/04/04 15:22:15 UTC

[07/10] git commit: updated refs/heads/master to 88c3171

fix Databases.Status.updateSeq for the case when a database has received no
updates (e.g. is newly created).


Project: http://git-wip-us.apache.org/repos/asf/couchdb/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb/commit/7bafe858
Tree: http://git-wip-us.apache.org/repos/asf/couchdb/tree/7bafe858
Diff: http://git-wip-us.apache.org/repos/asf/couchdb/diff/7bafe858

Branch: refs/heads/master
Commit: 7bafe8582d9f3dbebd286582400560e0e1bbbd6d
Parents: b420843
Author: Simon Metson <si...@cloudant.com>
Authored: Thu Apr 4 13:08:20 2013 +0100
Committer: Simon Metson <me...@apache.org>
Committed: Thu Apr 4 13:08:20 2013 +0100

----------------------------------------------------------------------
 src/fauxton/app/modules/databases/resources.js |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/couchdb/blob/7bafe858/src/fauxton/app/modules/databases/resources.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/modules/databases/resources.js b/src/fauxton/app/modules/databases/resources.js
index e5d3fae..59dd179 100644
--- a/src/fauxton/app/modules/databases/resources.js
+++ b/src/fauxton/app/modules/databases/resources.js
@@ -104,8 +104,10 @@ function(app, FauxtonAPI, Documents) {
       var updateSeq = this.get("update_seq");
       if (full || (typeof(updateSeq) === 'number')) {
         return updateSeq;
-      } else {
+      } else if (updateSeq) {
         return updateSeq.split('-')[0];
+      } else {
+        return 0;
       }
     },