updated functionality to use Filestore class and its methods