aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTeddy Wing2018-08-04 19:55:03 +0200
committerTeddy Wing2018-08-04 19:55:03 +0200
commitdbebdabda3eb1f3edc52328c2c069c7c6b3fc9ab (patch)
tree52ac425004a1a79e90b854091e73ab9a115d09ed
parent6d9a9e792918389bae732a7ccc33741bf449dccb (diff)
downloadLegibility-dbebdabda3eb1f3edc52328c2c069c7c6b3fc9ab.tar.bz2
content.js: Include subdomain
Include the subdomain when matching filenames. This is less general, but allows us to match more precisely. I needed to modify CSS on a `subdomain.github.io` blog, and of course we don't want to modify _all_ `github.io` styles.
-rw-r--r--content.js5
1 files changed, 1 insertions, 4 deletions
diff --git a/content.js b/content.js
index 0dbcb50..e970e79 100644
--- a/content.js
+++ b/content.js
@@ -21,9 +21,6 @@ if (chrome) {
browser = chrome;
}
-var domain = location.hostname
- .split('.')
- .slice(-2)
- .join('.');
+var domain = location.hostname;
browser.runtime.sendMessage({ domain: domain });