Fix #308 - fs.rename does not work on directories
Merge pull request #309 from gideonthomas/issue308

Fix #308 - fs.rename does not work on directories
Fix #334 - Do not allow fs.link on directories