Tidy up how the debugging printing is enabled or not.