diff --git a/4chan_x.user.js b/4chan_x.user.js index 2fde6b1af..2aa249c7d 100644 --- a/4chan_x.user.js +++ b/4chan_x.user.js @@ -2175,8 +2175,8 @@ sauce = { init: function() { sauce.prefixes = conf['flavors'].match(/^[^#].+$/gm); - sauce.names = sauce.prefixes.map(function(s) { - return s.match(/\w+(?=\.)/)[0]; + sauce.names = sauce.prefixes.map(function(prefix) { + return prefix.match(/(\w+)\./)[1]; }); return g.callbacks.push(function(root) { var i, link, prefix, span, suffix, _len, _ref, _results; diff --git a/script.coffee b/script.coffee index 4432f81a9..c54ff7fcc 100644 --- a/script.coffee +++ b/script.coffee @@ -1647,7 +1647,7 @@ anonymize = sauce = init: -> sauce.prefixes = conf['flavors'].match /^[^#].+$/gm - sauce.names = sauce.prefixes.map (s) -> s.match(/\w+(?=\.)/)[0] + sauce.names = sauce.prefixes.map (prefix) -> prefix.match(/(\w+)\./)[1] g.callbacks.push (root) -> return if root.className is 'inline' or not span = $ '.filesize', root suffix = $('a', span).href