Return a git.Tree object matching a tag ref fetched into refs/tags/

def get_tree_from_tag(self, ref):
        '''
        Return a git.Tree object matching a tag ref fetched into refs/tags/
        '''
        try:
            return git.TagReference(
                self.repo,
                'refs/tags/{0}'.format(ref)).commit.tree
        except ValueError:
            return None