remove unneded commented code, rework logging, so check modules can also use it