replace old %-formatted and .format(…) strings with f-strings (#7671)
mostly using flynt https://github.com/ikamensh/flynt
This commit is contained in:
@@ -28,8 +28,8 @@ class _2chanThreadExtractor(Extractor):
|
||||
self.server, self.board, self.thread = match.groups()
|
||||
|
||||
def items(self):
|
||||
url = "https://{}.2chan.net/{}/res/{}.htm".format(
|
||||
self.server, self.board, self.thread)
|
||||
url = (f"https://{self.server}.2chan.net"
|
||||
f"/{self.board}/res/{self.thread}.htm")
|
||||
page = self.request(url).text
|
||||
data = self.metadata(page)
|
||||
yield Message.Directory, data
|
||||
|
||||
Reference in New Issue
Block a user