Fixed trimDot.

I fixed problem with processing path with slash on begin or double slash inside.
Before my change trimDot convert ["path", "", "path2", "..", "file"] to ["path", "", "path2", "..", "file"] - stops loop on empty string. After my change ["path", "", "path2", "..", "file"] convert to ["path", "", "file"].