Fix Directory Assertion
Apparently path() is not guaranteed to return a trailing slash in case of directories.
REVIEW: 123203