cleaned up debug log wrapper