ShortestDijkstra error: Solution exception:Index was outside array bounds

Hi everyone,
I am having a problem while using decoding spaces toolbox’s shortestdijkstra tool. I used the same code in a different plan and it worked, but I don’t know why I am having this problem this time. The error is a common error, I can’t understand what it is trying to tell me.
Thanks for your help!

planareasw.3dm (732.0 KB)
planareasw.gh (43.7 KB)