fixed some encoding problems
added logging