It is needed because the file might have been partially loaded when we hit an exception so I think is better to return the variable to a known value