check if path is exists
Merge pull request #321 from newscred/fix-path-error

check if path is exists