You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@couchdb.apache.org by ro...@apache.org on 2014/09/08 15:29:34 UTC
[3/4] fauxton commit: updated refs/heads/master to 36957d0
Allow replications to existing databases
Project: http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/commit/7d9daf5c
Tree: http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/tree/7d9daf5c
Diff: http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/diff/7d9daf5c
Branch: refs/heads/master
Commit: 7d9daf5c73c63f431ff251ee9c55e8edd1dae514
Parents: be42054
Author: Robert Kowalski <ro...@kowalski.gd>
Authored: Mon Sep 1 01:36:00 2014 +0200
Committer: Robert Kowalski <ro...@kowalski.gd>
Committed: Mon Sep 8 15:30:39 2014 +0200
----------------------------------------------------------------------
app/addons/replication/views.js | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/blob/7d9daf5c/app/addons/replication/views.js
----------------------------------------------------------------------
diff --git a/app/addons/replication/views.js b/app/addons/replication/views.js
index a138beb..1a6936d 100644
--- a/app/addons/replication/views.js
+++ b/app/addons/replication/views.js
@@ -101,18 +101,19 @@ function(app, FauxtonAPI, Components, Replication) {
type: "error",
clear: true
});
+ return;
}else if (this.$('input#to_name').is(':visible') && !this.$('input[name=create_target]').is(':checked')){
var alreadyExists = this.collection.where({"name":this.$('input#to_name').val()});
- if (alreadyExists.length === 0){
- notification = FauxtonAPI.addNotification({
+ if (alreadyExists.length === 0) {
+ FauxtonAPI.addNotification({
msg: "This database doesn't exist. Check create target if you want to create it.",
type: "error",
clear: true
});
+ return;
}
- }else{
- this.submit(e);
}
+ this.submit(e);
},
formValidation: function(e){
var $remote = this.$el.find('input:visible'),