Add warning method in logger class