Return-Path: Delivered-To: apmail-couchdb-commits-archive@www.apache.org Received: (qmail 84056 invoked from network); 18 Aug 2009 15:17:34 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 18 Aug 2009 15:17:34 -0000 Received: (qmail 1475 invoked by uid 500); 18 Aug 2009 15:17:53 -0000 Delivered-To: apmail-couchdb-commits-archive@couchdb.apache.org Received: (qmail 1401 invoked by uid 500); 18 Aug 2009 15:17:53 -0000 Mailing-List: contact commits-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@couchdb.apache.org Delivered-To: mailing list commits@couchdb.apache.org Received: (qmail 1392 invoked by uid 99); 18 Aug 2009 15:17:53 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 18 Aug 2009 15:17:53 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 18 Aug 2009 15:17:50 +0000 Received: by eris.apache.org (Postfix, from userid 65534) id 85FA623888CD; Tue, 18 Aug 2009 15:17:29 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r805445 - /couchdb/trunk/share/www/script/couch_tests.js Date: Tue, 18 Aug 2009 15:17:29 -0000 To: commits@couchdb.apache.org From: jan@apache.org X-Mailer: svnmailer-1.0.8 Message-Id: <20090818151729.85FA623888CD@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: jan Date: Tue Aug 18 15:17:29 2009 New Revision: 805445 URL: http://svn.apache.org/viewvc?rev=805445&view=rev Log: unset new config values on run_on_modified_server rollback Modified: couchdb/trunk/share/www/script/couch_tests.js Modified: couchdb/trunk/share/www/script/couch_tests.js URL: http://svn.apache.org/viewvc/couchdb/trunk/share/www/script/couch_tests.js?rev=805445&r1=805444&r2=805445&view=diff ============================================================================== --- couchdb/trunk/share/www/script/couch_tests.js [utf-8] (original) +++ couchdb/trunk/share/www/script/couch_tests.js [utf-8] Tue Aug 18 15:17:29 2009 @@ -117,10 +117,16 @@ // unset the settings for(var j=0; j < i; j++) { var s = settings[j]; - CouchDB.request("PUT", "/_config/" + s.section + "/" + s.key, { - body: s.oldValue, - headers: {"X-Couch-Persist": "false"} - }); + if(s.oldValue == "\"\"\n") { // unset value + CouchDB.request("DELETE", "/_config/" + s.section + "/" + s.key, { + headers: {"X-Couch-Persist": "false"} + }); + } else { + CouchDB.request("PUT", "/_config/" + s.section + "/" + s.key, { + body: s.oldValue, + headers: {"X-Couch-Persist": "false"} + }); + } } } }