Skip to content

Commit

Permalink
adds underscore randomizer
Browse files Browse the repository at this point in the history
  • Loading branch information
Brock Whitten committed Mar 17, 2017
1 parent fe2062c commit 0d7e643
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
9 changes: 8 additions & 1 deletion lib/middleware/domain.js
Expand Up @@ -45,6 +45,13 @@ module.exports = function(req, next, abort){
console.log(label, req.domain)
next()
} else {
getDomain(req.suggestedDomain)
if (req.domain == "_"){
req.domain = [moniker.choose(), req.config.platform].join(".")
console.log(label, req.domain)
next()
} else {
getDomain(req.suggestedDomain)
}

}
}
2 changes: 1 addition & 1 deletion package.json
@@ -1,6 +1,6 @@
{
"name": "surge",
"version": "0.18.0",
"version": "0.19.0",
"description": "CDN for front-end developers",
"author": "Brock Whitten <brock@chloi.io>",
"bin": "./lib/cli.js",
Expand Down

0 comments on commit 0d7e643

Please sign in to comment.