avoid possible NPE for non-existing paths