Permalink
Browse files

fixed `search()` params

  • Loading branch information...
1 parent e92640d commit 1cca5b5539d8e87098ba8da52d35da713f3d8f15 @fent fent committed Apr 3, 2012
Showing with 4 additions and 4 deletions.
  1. +4 −4 lib/dropbox-node.js
View
@@ -130,8 +130,7 @@ DropboxClient.prototype.getFile = function(path, optargs, cb) {
}
-// Uploads contents of a file specified by path argument, relative to
-// application's directory.
+// Uploads contents of a file specified by file to the remote path
DropboxClient.prototype.putFile = function(file, path, optargs, cb) {
if (typeof optargs == 'function') cb = optargs, optargs = {};
var uri = CONTENT_API_URI + '/files_put/dropbox/' + escapePath(path) +
@@ -228,8 +227,9 @@ DropboxClient.prototype.move = function(from_path, to_path, optargs, cb) {
// See https://www.dropbox.com/developers/reference/api#search
DropboxClient.prototype.search = function(path, query, optargs, cb) {
if (typeof optargs === 'function') cb = optargs, optargs = {};
+ optargs.query = query;
var uri = API_URI + '/search/dropbox/' + escapePath(path) + '?' +
- querystring.stringify({query: query});
+ stringifyParams(optargs);
this.get(uri, optargs, cb);
}
@@ -259,7 +259,7 @@ DropboxClient.prototype.delta = function(cursor, optargs, cb) {
// Returns an event emitter that has `pause()` and `resume()` methods.
// It emits `reset` events on detta resets, and `data` events with
// parameters `path` and `metadata` on new delta changes.
-DropboxClient.prototype.stream = function(cursor, optargs) {
+DropboxClient.prototype.changesStream = function(cursor, optargs) {
optargs = optargs || {};
var ee = new EventEmitter();
var iid;

0 comments on commit 1cca5b5

Please sign in to comment.