mirror of
https://github.com/less/less.js.git
synced 2026-04-09 03:00:20 -04:00
Merge pull request #1643 from matthewp/location-port
Check location.port for truthiness
This commit is contained in:
@@ -8,7 +8,8 @@ var isFileProtocol = /^(file|chrome(-extension)?|resource|qrc|app):/.test(locati
|
||||
less.env = less.env || (location.hostname == '127.0.0.1' ||
|
||||
location.hostname == '0.0.0.0' ||
|
||||
location.hostname == 'localhost' ||
|
||||
location.port.length > 0 ||
|
||||
(location.port &&
|
||||
location.port.length > 0) ||
|
||||
isFileProtocol ? 'development'
|
||||
: 'production');
|
||||
|
||||
|
||||
Reference in New Issue
Block a user