Commit fea94d31 authored by Kevin Paxman's avatar Kevin Paxman
Browse files

RT-1106449: use patch from...

RT-1106449: use patch from https://www.drupal.org/project/ckeditor_link/issues/1491750#comment-13794091 to properly guess links
parent 95877166
......@@ -77,9 +77,10 @@
return cache[value];
}
$.getJSON(Drupal.settings.ckeditor_link.revert_path + '/' + Drupal.encodePath(path), function(data) {
var basePath = Drupal.settings.basePath;
var base = extractPath(data);
var pos = path.lastIndexOf(base);
var args = (pos != -1) ? value.substr(pos + base.length + 1) : '';
var args = (pos != -1) ? value.substr(pos + basePath.length + base.length) : '';
args = (args.charAt(0) == '/') ? args.substr(1) : args;
cache[value] = {
path: data,
......@@ -252,4 +253,4 @@
});
}
});
})(jQuery);
\ No newline at end of file
})(jQuery);
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment