JonAbrams / synth

The first back-end framework specially designed for single-page web applications
http://www.synthjs.com
MIT License
969 stars 70 forks source link

Handle non-folders in back/resources #38

Closed mikaelhm closed 10 years ago

mikaelhm commented 10 years ago

The lib/handlersParser.js should be able to handle non-folders in the resources folder better.

I got this error when a hidden OS X file sneaked it self into the folder:

Error: ENOTDIR, not a directory '/data/generator/back/resources/.DS_Store'
  at Object.fs.readdirSync (fs.js:654:18)
  at parseDir (/data/generator/back/node_modules/synth/lib/handlersParser.js:115:23)
  at /data/generator/back/node_modules/synth/lib/handlersParser.js:123:9
  at Array.forEach (native)
  at parseDir (/data/generator/back/node_modules/synth/lib/handlersParser.js:116:14)
  at Object.exports.parse (/data/generator/back/node_modules/synth/lib/handlersParser.js:127:5)
  at module.exports (/data/generator/back/node_modules/synth/synth.js:38:29)
  at Object.<anonymous> (/data/generator/back/back-app.js:27:18)
  at Module._compile (module.js:456:26)
  at Object.Module._extensions..js (module.js:474:10)
  at Module.load (module.js:356:32)
  at Function.Module._load (module.js:312:12)
  at Module.require (module.js:364:17)
  at require (module.js:380:17)
  at Object.<anonymous> (/data/generator/back/app.js:2:11)
  at Module._compile (module.js:456:26)
  at Object.Module._extensions..js (module.js:474:10)
  at Module.load (module.js:356:32)
  at Function.Module._load (module.js:312:12)
  at Function.Module.runMain (module.js:497:10)
  at startup (node.js:119:16)
  at node.js:902:3
JonAbrams commented 10 years ago

Thanks for raising the issue, it's a good one! It should be fixed in the new version, 0.5.0, that I just published to npm.

mikaelhm commented 10 years ago

Great thanks! Den 21/06/2014 16.08 skrev "Jon Abrams" notifications@github.com:

Thanks for raising the issue, it's a good one! It should be fixed in the new version, 0.5.0, that I just published to npm.

— Reply to this email directly or view it on GitHub https://github.com/JonAbrams/synth/issues/38#issuecomment-46767370.