CouchDB
  1. CouchDB
  2. COUCHDB-1016

$.couch.replicate throws error when cancelling continous replication

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Trivial Trivial
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.0.3, 1.1, 1.2
    • Component/s: Replication
    • Labels:
      None
    • Skill Level:
      New Contributors Level (Easy)

      Description

      Calling $.couch.replicate with

      { continous: true, cancel: true }

      results in an alert error message. Should be quiet and call success handler.

      Patch:

      diff --git a/share/www/script/jquery.couch.js b/share/www/script/jquery.couch.js
      index 114e580..14d2506 100644
      — a/share/www/script/jquery.couch.js
      +++ b/share/www/script/jquery.couch.js
      @@ -563,7 +563,7 @@

      replicate: function(source, target, ajaxOptions, repOpts) {
      repOpts = $.extend(

      {source: source, target: target}

      , repOpts);

      • if (repOpts.continuous) {
        + if (repOpts.continuous && !repOpts.cancel) { ajaxOptions.successStatus = 202; }

        ajax({

        Issue Links

          Activity

          Felix Hummel created issue -
          Hide
          Jan Lehnardt added a comment -

          Committed, thanks.

          Show
          Jan Lehnardt added a comment - Committed, thanks.
          Jan Lehnardt made changes -
          Field Original Value New Value
          Status Open [ 1 ] Resolved [ 5 ]
          Fix Version/s 1.0.3 [ 12316107 ]
          Fix Version/s 1.1 [ 12314933 ]
          Fix Version/s 1.2 [ 12315198 ]
          Resolution Fixed [ 1 ]
          Jan Lehnardt made changes -
          Link This issue is related to COUCHDB-1115 [ COUCHDB-1115 ]

            People

            • Assignee:
              Unassigned
              Reporter:
              Felix Hummel
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development