mirror of
https://github.com/status-im/PyGithub.git
synced 2026-08-31 19:01:15 +00:00
Set line length to 120 characters (#2599)
This commit is contained in:
+4
-14
@@ -88,10 +88,7 @@ class TimelineEvent(github.GithubObject.NonCompletableGithubObject):
|
||||
:type: :class:`github.TimelineEventSource.TimelineEventSource`
|
||||
"""
|
||||
# only available on `cross-referenced` events.
|
||||
if (
|
||||
self.event == "cross-referenced"
|
||||
and self._source is not github.GithubObject.NotSet
|
||||
):
|
||||
if self.event == "cross-referenced" and self._source is not github.GithubObject.NotSet:
|
||||
return self._source.value
|
||||
return None
|
||||
|
||||
@@ -109,10 +106,7 @@ class TimelineEvent(github.GithubObject.NonCompletableGithubObject):
|
||||
"""
|
||||
:type string
|
||||
"""
|
||||
if (
|
||||
self.event == "commented"
|
||||
and self._author_association is not github.GithubObject.NotSet
|
||||
):
|
||||
if self.event == "commented" and self._author_association is not github.GithubObject.NotSet:
|
||||
return self._author_association.value
|
||||
return None
|
||||
|
||||
@@ -138,9 +132,7 @@ class TimelineEvent(github.GithubObject.NonCompletableGithubObject):
|
||||
|
||||
def _useAttributes(self, attributes):
|
||||
if "actor" in attributes: # pragma no branch
|
||||
self._actor = self._makeClassAttribute(
|
||||
github.NamedUser.NamedUser, attributes["actor"]
|
||||
)
|
||||
self._actor = self._makeClassAttribute(github.NamedUser.NamedUser, attributes["actor"])
|
||||
if "commit_id" in attributes: # pragma no branch
|
||||
self._commit_id = self._makeStringAttribute(attributes["commit_id"])
|
||||
if "created_at" in attributes: # pragma no branch
|
||||
@@ -160,8 +152,6 @@ class TimelineEvent(github.GithubObject.NonCompletableGithubObject):
|
||||
if "body" in attributes: # pragma no branch
|
||||
self._body = self._makeStringAttribute(attributes["body"])
|
||||
if "author_association" in attributes: # pragma no branch
|
||||
self._author_association = self._makeStringAttribute(
|
||||
attributes["author_association"]
|
||||
)
|
||||
self._author_association = self._makeStringAttribute(attributes["author_association"])
|
||||
if "url" in attributes: # pragma no branch
|
||||
self._url = self._makeStringAttribute(attributes["url"])
|
||||
|
||||
Reference in New Issue
Block a user