function handleDefault(handler, req, resp) {
    try {
      this._handleDefault(handler, req, resp);
    } catch (e) {
      if (e instanceof HttpError) {
        this.respond(req, resp, e.code, e.description, "", {});
      } else {
        throw e;
      }
    }
  }
/**
   * This is invoked by the HttpServer. `this` is bound to the SyncServer;
   * `handler` is the HttpServer's handler.
   *
   * TODO: need to use the correct Sync API response codes and errors here.
   * TODO: Basic Auth.
   * TODO: check username in path against username in BasicAuth.
   */
This is invoked by the HttpServer. `this` is bound to the SyncServer;
`handler` is the HttpServer's handler.

need to use the correct Sync API response codes and errors here.
TODO: Basic Auth.
TODO: check username in path against username in BasicAuth.
This is invoked by the HttpServer . ` this ` is bound to the SyncServer ; ` handler ` is the HttpServer ' s handler . need to use the correct Sync API response codes and errors here . TODO : Basic Auth . TODO : check username in path against username in BasicAuth .
function handleDefault(handler, req, resp) {
    try {
      this._handleDefault(handler, req, resp);
    } catch (e) {
      if (e instanceof HttpError) {
        this.respond(req, resp, e.code, e.description, "", {});
      } else {
        throw e;
      }
    }
  }
function handleDefault ( handler , req , resp ) { try { this . _handleDefault ( handler , req , resp ) ; } catch ( e ) { if ( e instanceof HttpError ) { this . respond ( req , resp , e . code , e . description , "" , { } ) ; } else { throw e ; } } }
This is invoked by the HttpServer.
This is invoked by the HttpServer .