Fixed a few logging issues.