Beispiel #1
0
def process_remove_tax_bracket(author: AccountId, message: str, server: Server,
                               **kwargs):
    assert_authorized(author, server, Authorization.ADMIN)
    results = parse_remove_tax_bracket(message)
    print(results)
    if results is None:
        raise CommandException('**WHY TF CAN\'T ANYBODY FORMAT FFS**')
    name = results
    server.remove_tax_bracket(author, name)
    return f"Success, I told you that you would end up needing to delete {name}; cus taxation is theft"
def remove_tax_bracket(author: Union[AccountId, str], name: str,
                       server: Server):
    """Remove tax bracket by name with authorization from author"""
    author = _get_account(author, server)
    _assert_authorized(author, None)
    server.remove_tax_bracket(author, name)