diff options
| author | Dennis Fink | 2026-11-14 18:44:23 +0100 |
|---|---|---|
| committer | Dennis Fink | 2026-11-14 18:44:23 +0100 |
| commit | 968e1b4e4a6fbd5a15037cdb11a3f9dee5108570 (patch) | |
| tree | 0096a0125c4d94a047e5bd24288e1f3f4a58ada5 /webmentions_ssg/tasks/mentions.py | |
| parent | 2366d455c7d1ae16c84e0bcbffb94ed762c16832 (diff) | |
| download | webmentions-ssg-968e1b4e4a6fbd5a15037cdb11a3f9dee5108570.tar.gz webmentions-ssg-968e1b4e4a6fbd5a15037cdb11a3f9dee5108570.zip | |
docs(core): standardize reST docstrings
Expand function and method documentation with consistent reST parameter,
return, and exception fields while clarifying behavior where additional
context is useful.
Normalize test and migration docstrings to the same documentation
conventions.
Diffstat (limited to 'webmentions_ssg/tasks/mentions.py')
| -rw-r--r-- | webmentions_ssg/tasks/mentions.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/webmentions_ssg/tasks/mentions.py b/webmentions_ssg/tasks/mentions.py index 8f41902..4c3918b 100644 --- a/webmentions_ssg/tasks/mentions.py +++ b/webmentions_ssg/tasks/mentions.py @@ -35,7 +35,7 @@ def html_mentions_target(body: bytes, source_url: str, target_url: str) -> bool: :param body: HTML document body. :param source_url: URL from which the document was retrieved. :param target_url: Exact URL to look for. - :return: Whether a supported HTML URL attribute references the target URL. + :returns: Whether a supported HTML URL attribute references the target URL. """ document = BeautifulSoup(body, "html.parser") base_url = source_url @@ -63,7 +63,7 @@ def text_mentions_target(body: str, target_url: str) -> bool: :param body: Plain-text document body. :param target_url: Exact IRI to look for. - :return: Whether the target IRI occurs in the document. + :returns: Whether the target IRI occurs in the document. """ for match in IRI_PATTERN.finditer(body): candidate = match.group() |
