Improved logging

Fixed #14