Added upload middleware in filestore.