turn off logging
sanitise input
turn off logging again