diff --git a/plugins/prefixIds.js b/plugins/prefixIds.js index d81fd0cc1..b57e43bd0 100644 --- a/plugins/prefixIds.js +++ b/plugins/prefixIds.js @@ -146,6 +146,10 @@ exports.fn = function(node, opts, extra) { if(prefix === false){ return escapeIdentifierName(name); } + if (name.startsWith(escapeIdentifierName(prefix) + opts.delim)) { + // Already prefixed! + return escapeIdentifierName(name); + } return escapeIdentifierName(prefix + opts.delim + name); };