added logging handler
Merge pull request #137 from d1ffuz0r/logging

added configurable logging handler
add io:format logger and fix logging condition