Fix builtin checkout crashing when given an invalid path