def commits(self):
        commits = self.data['commits']
        branch = self.data['ref'].replace("refs/heads/", "")
        branch_url = self.data['repository']['html_url'] + "/tree/" + branch
        if not commits:
            commits = [self.data['head_commit']]
        changeset = "changesets" if len(commits) > 1 else "changeset"
        msg = []
        msg.append((self.user_link(), len(commits), changeset, branch, branch_url, self.repo_link()) % "%s pushed %s %s to [%s](%s) at %s:")
        for commit in commits:
            cid  = commit['id'][:7]
            curl = commit['url']
            cmsg = self.preview(commit['message'])
            ctext = "- [`%s`](%s): %s" % (cid, curl, cmsg)
            msg.append("\n")
            msg.append(ctext)
        return "".join(msg)
dataset/ETHPy150Open softdevteam/mattermost-github-integration/payload.py/Push.commits/swapped operands of `%`