Fix ShortestPaths

Fixed error when creating the data.frame with result, now checks the
length of outgoing and ingoing result before rbind data.frame