revert this; first do ```if path is None```, then the else block