Skip to content

Commit

Permalink
style: use underscores for internal methods more consistently
Browse files Browse the repository at this point in the history
  • Loading branch information
Ned Batchelder authored and nedbat committed Oct 4, 2023
1 parent 2a57f30 commit 2b83ff3
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions openedx_webhooks/tasks/pr_tracking.py
Original file line number Diff line number Diff line change
Expand Up @@ -334,18 +334,18 @@ def fix(self) -> None:
self.actions.set_cla_status(status=self.desired.cla_check)

if self.desired.is_ospr:
self.fix_ospr()
self._fix_ospr()

if self.desired.is_refused:
self.fix_comments()
self._fix_comments()

# Make needed Jira issues.
current_jira_nicks = {ji.nick for ji in self.current.bot_data.jira_issues}
for jira_nick in self.desired.jira_nicks:
if jira_nick not in current_jira_nicks:
self._make_jira_issue(jira_nick)

def fix_comments(self) -> None:
def _fix_comments(self) -> None:
fix_comment = True
if self.pr["state"] == "closed" and self.current.bot_comments:
# If the PR is closed and already has bot comments, then don't
Expand All @@ -355,15 +355,15 @@ def fix_comments(self) -> None:
self._fix_bot_comment()
self._add_bot_comments()

def fix_ospr(self) -> None:
def _fix_ospr(self) -> None:
# Draftiness
self.bot_data.draft = is_draft_pull_request(self.pr)

# Check the GitHub labels.
self._fix_github_labels()

# Check the bot comments.
self.fix_comments()
self._fix_comments()

# Check the GitHub projects.
for project in (self.desired.github_projects - self.current.github_projects):
Expand Down

0 comments on commit 2b83ff3

Please sign in to comment.