From 03e7fbd781846ea4438ab3c553e54e06cf1ff06e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luk=C3=A1=C5=A1=20Kucharczyk?= Date: Thu, 29 Apr 2021 19:15:02 +0200 Subject: [PATCH] Try to get the extension to pick up the file --- hacker_news_redirect/hn_premii_com_redirect.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/hacker_news_redirect/hn_premii_com_redirect.js b/hacker_news_redirect/hn_premii_com_redirect.js index a335b15..ca5cf27 100644 --- a/hacker_news_redirect/hn_premii_com_redirect.js +++ b/hacker_news_redirect/hn_premii_com_redirect.js @@ -7,4 +7,7 @@ // @author Lukas Kucharczyk (lukas@kucharczyk.xyz) // @description Automatically redirects Hacker News links to a more modern interface at hn.premii.com. // ==/UserScript== -window.location.href='https://hn.premii.com/#/comments/' + new URLSearchParams(window.location.search).get('id') \ No newline at end of file +(function() +{ + window.location.href='https://hn.premii.com/#/comments/' + new URLSearchParams(window.location.search).get('id') +})(); \ No newline at end of file