Fix to ensure lang file registration doesn't stop if an exception is caught