Fix exception in _getMonoCurves() when path is empty.

Closes #427.