Implement fs.commit