more url info to make debugging easier
This commit is contained in:
parent
4da591c926
commit
b0ff8bca57
|
@ -212,7 +212,7 @@ module.exports.create = function (webserver, xconfx, state) {
|
||||||
|
|
||||||
if (!/^api\.[a-z0-9\-]+/.test(hostname)) {
|
if (!/^api\.[a-z0-9\-]+/.test(hostname)) {
|
||||||
res.send({ error:
|
res.send({ error:
|
||||||
{ message: "['" + hostname + "'] API access is restricted to proper 'api'-prefixed lowercase subdomains."
|
{ message: "['" + hostname + req.url + "'] API access is restricted to proper 'api'-prefixed lowercase subdomains."
|
||||||
+ " The HTTP 'Host' header must exist and must begin with 'api.' as in 'api.example.com'."
|
+ " The HTTP 'Host' header must exist and must begin with 'api.' as in 'api.example.com'."
|
||||||
+ " For development you may test with api.localhost.daplie.me (or any domain by modifying your /etc/hosts)"
|
+ " For development you may test with api.localhost.daplie.me (or any domain by modifying your /etc/hosts)"
|
||||||
, code: 'E_NOT_API'
|
, code: 'E_NOT_API'
|
||||||
|
|
Loading…
Reference in New Issue