fixed a few bugs relating to the file store, set returns json rather than a buffer