Fix pom and a bug with the shortestpath function