Skip to content

Commit

Permalink
Make scheme a cached property as well
Browse files Browse the repository at this point in the history
Noticed this one comes up a lot while profiling #1039
  • Loading branch information
bdraco committed Aug 30, 2024
1 parent 84e1c7d commit b64e96a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion yarl/_url.py
Original file line number Diff line number Diff line change
Expand Up @@ -434,7 +434,7 @@ def relative(self):
val = self._val._replace(scheme="", netloc="")
return URL(val, encoded=True)

@property
@cached_property
def scheme(self):
"""Scheme for absolute URLs.
Expand Down

0 comments on commit b64e96a

Please sign in to comment.