Skip to content

Commit

Permalink
fixup! tools, calc: fix incomplete type defs
Browse files Browse the repository at this point in the history
  • Loading branch information
Exirel committed Oct 14, 2024
1 parent 3805665 commit bc7b2b5
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions sopel/tools/identifiers.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,9 +97,8 @@ def rfc1459_strict_lower(text: str) -> str:
class Identifier(str):
"""A ``str`` subclass which acts appropriately for IRC identifiers.
:param str identifier: IRC identifier
:param identifier: IRC identifier
:param casemapping: a casemapping function (optional keyword argument)
:type casemapping: Callable[[:class:`str`], :class:`str`]
When used as normal ``str`` objects, case will be preserved.
However, when comparing two Identifier objects, or comparing an Identifier
Expand Down Expand Up @@ -165,9 +164,8 @@ def lower(self) -> str:
def _lower(identifier: str) -> str:
"""Convert an identifier to lowercase per :rfc:`2812`.
:param str identifier: the identifier (nickname or channel) to convert
:param identifier: the identifier (nickname or channel) to convert
:return: RFC 2812-compliant lowercase version of ``identifier``
:rtype: str
:meta public:
Expand All @@ -191,7 +189,6 @@ def _lower_swapped(identifier: str) -> str:
:param identifier: the identifier (nickname or channel) to convert
:return: RFC 2812-non-compliant lowercase version of ``identifier``
:rtype: str
This is what the old :meth:`_lower` function did before Sopel 7.0. It
maps ``{}``, ``[]``, ``|``, ``\\``, ``^``, and ``~`` incorrectly.
Expand Down

0 comments on commit bc7b2b5

Please sign in to comment.