Add more logging
Fix undefined variable usage (1.4.1)
Merge pull request #1 from elsid/more_log

More log