added support for unique paths