tidy up, some refactoring
sequencefile storage fixes