Cannot find module './Waze/Action/ModifyConnection.js'

I’ve been using the “WME Add Uturns from node” script quite a while, but now it has stopped working. I get the following error: “Cannot find module ‘./Waze/Action/ModifyConnection.js’”.

It seems like the ModifyConnection module has been replaced in the API? Does anyone know how to fix this code? From what I can see the problems are here:

var wazeActionModifyConnection= require("Waze/Action/ModifyConnection") //module does not exist any more. 

var node = Waze.selectionManager.selectedItems[0].model;
      var segIDs = node.attributes.segIDs;
      
      for (var i = 0; i < segIDs.length; i++) {
          var segment = Waze.model.segments.objects[segIDs[i]];
          
          if (segment.attributes.fromNodeID == node.attributes.id) {
              console.log('А', segment.attributes.id);
              
              segment.attributes.fromConnections[segment.attributes.id] = true; //fromConnections is not a property of attributes any longer
              Waze.model.actionManager.add(new wazeActionModifyConnection(segment.attributes.id, segment.getFromNode(), segment.attributes.id,segment.getFromNode()));

I don’t know the answer to your question but what script is it? I have never heard of “WME Add Uturns from node” Is it part of another script or is that the name of it?

It’s the name of the script.

Waze/Action/ModifictionConnection has been removed

Yes, that’s what I said… The question is what it has been replaced with!

Nothing that i have found.

Well, the functionality is still there in WME. Maybe someone else know?

This script?

Fixed mod, now works fine in the editor - https://drive.google.com/open?id=0B9Z7EgB7uYAuU2JKTG5Ed2ZNTmM

Thanks! Works perfectly!