Fixed some last-minute stuff with logging