Fixing Is Path exists and valid path validation