Fix throwing on clearing errors of unknown file