Fixed #148 - input dir path doesn't need to end with '/'