Skip to content

Commit

Permalink
fix backport ready for PyGithub 2
Browse files Browse the repository at this point in the history
  • Loading branch information
kmaehashi committed Aug 29, 2023
1 parent 07d5c93 commit 4aa9c79
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions backport.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,15 +90,15 @@ def git(args: list[str], cd: Optional[str] = None) -> None:
print('')


class App(object):
class App:
def __init__(
self, token: str, organ_name: str, repo_name: str,
debug: bool = False):
assert isinstance(organ_name, str)
assert isinstance(repo_name, str)
self.repo_name = repo_name
self.organ_name = organ_name
self.g = github.Github(token)
self.g = github.Github(auth=github.Auth.Token(token))
self.repo = self.g.get_repo('{}/{}'.format(organ_name, repo_name))
self.user_name = self.g.get_user().login
self.debug = debug
Expand Down

0 comments on commit 4aa9c79

Please sign in to comment.