sintaxi / dbox

NodeJS SDK for Dropbox API (THIS LIBRARY IS OBSOLETE!!)
514 stars 91 forks source link

The method readdir() not working, returning 400 and no error... #70

Open moreofmorris opened 10 years ago

moreofmorris commented 10 years ago

Hey.

The readdir() method is not working it seems. Everything else in the API is returning nicely, but with readdir() I simply get a 400 status with nothing else returned. If it returned an error I could then try and diagnose the problem. At present I get [] and that's it.

As for it not working, I've tried adding the root (which is 'dropbox' like everything else) but nothing happens.

Thanks! James

charliebecker commented 10 years ago

I found that you need to modify the self.metadata call in the readdir section to include {root: options.root}. The issue is the readdir method calls the metadata method but fails to pass the root option.

          self.metadata(path, {root: options.root}, function (status, reply) {