def METHOD_NAME(wrapped_obj, category, action):
    """Utility function to run action"""
    if _ENABLE_DECORATOR:
        message = message_format.format(wrapped_obj, category.name)
        if action == Action.ERROR:
            raise RuntimeError(message)
        if action == Action.WARNING:
            log.warning(message)