Can't rename a file?
Opened this issue · 1 comments
jpetitcolas commented
I try to rename a file using:
yield fs.rename(src, dest);
Yet, I got the following error:
TypeError: You may only yield a function, promise, generator, array, or object, but the following object was passed: "undefined"
at next (/home/jpetitcolas/dev/xxx/node_modules/koa/node_modules/co/index.js:101:25)
at onFulfilled (/home/jpetitcolas/dev/xxx/node_modules/koa/node_modules/co/index.js:69:7)
fs.js:77
throw err; // Forgot a callback but don't know where? Use NODE_DEBUG=fs
^
Error: EXDEV, rename '/tmp/lazg2qxdek4kj4i/file.png'
I am using Koa 1.0.0 and co-fs 1.2.0. Any idea? :)
yuanjack commented
+1