Finished logging
Bugfixes