Skip to content
This repository has been archived by the owner on Jun 7, 2023. It is now read-only.

Commit

Permalink
Address CR: use wgWikiaBaseDomainRegex
Browse files Browse the repository at this point in the history
  • Loading branch information
KockaAdmiralac committed Oct 24, 2018
1 parent 4f2bafc commit 257bffd
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions skins/common/wikibits.js
Original file line number Diff line number Diff line change
Expand Up @@ -87,13 +87,7 @@ function maybeRedirectDevWikiCodeSubpage(url) {
url.indexOf(mw.config.get('wgScript')) != -1 &&
(
mw.config.get('wgCityId') === '7931' ||
// Check protocol-relative, HTTP and HTTPS versions of Dev Wiki links
// This is done via wgWikiaBaseDomain so fandom.com migration does
// not affect it and can't use wgWikiaBaseDomainRegex so it does
// not potentially affect devbox URLs such as dev.wikia-dev.pl
url.indexOf('//dev.' + mw.config.get('wgWikiaBaseDomain')) === 0 ||
url.indexOf('http://dev.' + mw.config.get('wgWikiaBaseDomain')) === 0 ||
url.indexOf('https://dev.' + mw.config.get('wgWikiaBaseDomain')) === 0
new RegExp('^(https?:)?\\/\\/dev\\.' + mw.config.get('wgWikiaBaseDomainRegex')).test(url)
) &&
(
url.indexOf('/code.js') !== -1 ||
Expand Down

0 comments on commit 257bffd

Please sign in to comment.