Fix for console mode.