leaf_focus/report/processing/normalise.py
def remove_suffix(self, value: str, suffixes: list[str]) -> str:
        """Remove the first matching suffix from the value."""
        if not value:
            return ""
        for suffix in suffixes:
            if value.endswith(suffix):
                match_len = len(suffix)
                return value[0:match_len]
        return value
Remove the first matching suffix from the value.
Remove the first matching suffix from the value.
Remove the first matching suffix from the value .
def remove_suffix(self, value: str, suffixes: list[str]) -> str:
        if not value:
            return ""
        for suffix in suffixes:
            if value.endswith(suffix):
                match_len = len(suffix)
                return value[0:match_len]
        return value
def remove_suffix ( self , value : str , suffixes : list [ str ] ) -> str : if not value : return "" for suffix in suffixes : if value . endswith ( suffix ) : match_len = len ( suffix ) return value [ 0 : match_len ] return value
Remove the first matching suffix from the value.
Remove the first matching suffix from the value .
"""Remove the first matching suffix from the value."""
self
value
str
suffixes
list[str]