On Wed, Apr 17, 2013 at 10:56 AM, Timo Schmidt <[email protected]> wrote: > Hello, > > I use this little Code: > console.log(file.path + ' does: '+fs.existsSync(file.path)); > fs.renameSync(file.path, __dirname+'/public/uploads/' + > file.name); > > The first line says that the file I want to copy exists, but the second > crashes, because it says that the file would not exist. (I checked it > myself, it exists!) > > Here is the log: > C:\Users\tsc\AppData\Local\Temp\985619c843276d1a16490f8d5b33db1a does: true > Error: ENOENT, no such file or directory > 'C:\Users\tsc\AppData\Local\Temp\985619c843276d1a16490f8d5b33db1a' > at Object.fs.renameSync (fs.js:439:18) > at categoriesOfPost (C:\Users\tsc\workspace\NCMS\routes\index.js:434:16) > at exports.saveCategories > (C:\Users\tsc\workspace\NCMS\routes\index.js:452:14) > at callbacks > (C:\Users\tsc\workspace\NCMS\node_modules\express\lib\router\index.js:161:37) > at param > (C:\Users\tsc\workspace\NCMS\node_modules\express\lib\router\index.js:135:11) > at pass > (C:\Users\tsc\workspace\NCMS\node_modules\express\lib\router\index.js:142:5) > at Router._dispatch > (C:\Users\tsc\workspace\NCMS\node_modules\express\lib\router\index.js:170:5) > at Object.router > (C:\Users\tsc\workspace\NCMS\node_modules\express\lib\router\index.js:33:10) > at next > (C:\Users\tsc\workspace\NCMS\node_modules\express\node_modules\connect\lib\proto.js:199:15) > at next > (C:\Users\tsc\workspace\NCMS\node_modules\express\node_modules\connect\lib\proto.js:201:9) > > > Why is this?!?!?!
Probably because of [1] and [2]. I have a patch for that but I need to rebase it against master. [1] https://github.com/joyent/node/issues/685 [2] https://github.com/joyent/node/issues/4314 -- -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/nodejs?hl=en?hl=en --- You received this message because you are subscribed to the Google Groups "nodejs" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.
