Implemented logging of all output