wimpy/util.py
def strip_suffix(s, suffix, strict=False):
    """Removes the suffix, if it's there, otherwise returns input string unchanged.
    If strict is True, also ensures the suffix was present"""
    if s.endswith(suffix):
        return s[: len(s) - len(suffix)]
    elif strict:
        raise WimpyError("string doesn't end with suffix")
    return s
def strip_suffix(s, suffix, strict=False):
    """Removes the suffix, if it's there, otherwise returns input string unchanged.
    If strict is True, also ensures the suffix was present"""
    if s.endswith(suffix):
        return s[: len(s) - len(suffix)]
    elif strict:
        raise WimpyError("string doesn't end with suffix")
    return s
Removes the suffix, if it's there, otherwise returns input string unchanged.
    If strict is True, also ensures the suffix was present