Add the logging