Added some more support for logging