Skip to content

Commit

Permalink
restore PR changes
Browse files Browse the repository at this point in the history
  • Loading branch information
Ibit-to authored Apr 5, 2019
1 parent 1ec2d96 commit 700a706
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions extension/u.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@ $(function () {
if (window.location.href.indexOf('//www.google') === -1) {
return
}
s = $('#search div.g').last()
var s = $('#search div.g').last()

$('div i > a').each(function (i, a) {
if (a.href.toLowerCase().indexOf('chillingeffects') === -1) {
return
}
id = a.href.replace(/https?:\/\/www\.chillingeffects\.org\/notice.cgi\?sID=/, '')
url = 'https://www.lumendatabase.org/notices/' + id
var id = a.href.replace(/https?:\/\/www\.chillingeffects\.org\/notice.cgi\?sID=/, '')
var url = 'https://www.lumendatabase.org/notices/' + id
if (navigator.userAgent.toLowerCase().indexOf('firefox') === -1) {
url = 'https://secret-ocean-49799.herokuapp.com/' + url
}
Expand All @@ -18,8 +18,8 @@ $(function () {
url: url,
dataType: 'html',
success: function (data) {
links = data.match(/>(https?:\/\/[^<]+)<\/li>/g)
for (i in links) {
var links = data.match(/>(https?:\/\/[^<]+)<\/li>/g)
for (var i in links) {
u = links[i].replace('</li>', '').replace('>', '')
s.after('<div class="g">'
+ '<a href="' + u + '" target="_blank">' + u + '</a>'
Expand Down

0 comments on commit 700a706

Please sign in to comment.