Improved logger handling.
Merge pull request #2 from beregond/logger

Improved logger handling.