def getsvfs(repo):
    """Return appropriate object to access files under .hg/store
    """
    svfs = getattr(repo, 'svfs', None)
    if svfs:
        return svfs
    else:
        return getattr(repo, 'sopener')
