Changes configuration example base_url for subdomainless users
This commit is contained in:
parent
351f9d763d
commit
8fe4224a55
@ -1,6 +1,6 @@
|
||||
// In case the base_url has a :user param the username will be the one specified in the URL,
|
||||
// otherwise it will fallback to extract the username from the host header.
|
||||
module.exports.base_url = '(?:/api/:version|/u/:user/api/:version)';
|
||||
module.exports.base_url = '(?:/api/:version|/user/:user/api/:version)';
|
||||
// If useProfiler is true every response will be served with an
|
||||
// X-SQLAPI-Profile header containing elapsed timing for various
|
||||
// steps taken for producing the response.
|
||||
|
@ -1,6 +1,6 @@
|
||||
// In case the base_url has a :user param the username will be the one specified in the URL,
|
||||
// otherwise it will fallback to extract the username from the host header.
|
||||
module.exports.base_url = '(?:/api/:version|/u/:user/api/:version)';
|
||||
module.exports.base_url = '(?:/api/:version|/user/:user/api/:version)';
|
||||
// If useProfiler is true every response will be served with an
|
||||
// X-SQLAPI-Profile header containing elapsed timing for various
|
||||
// steps taken for producing the response.
|
||||
|
@ -1,6 +1,6 @@
|
||||
// In case the base_url has a :user param the username will be the one specified in the URL,
|
||||
// otherwise it will fallback to extract the username from the host header.
|
||||
module.exports.base_url = '(?:/api/:version|/u/:user/api/:version)';
|
||||
module.exports.base_url = '(?:/api/:version|/user/:user/api/:version)';
|
||||
// If useProfiler is true every response will be served with an
|
||||
// X-SQLAPI-Profile header containing elapsed timing for various
|
||||
// steps taken for producing the response.
|
||||
|
@ -1,6 +1,6 @@
|
||||
// In case the base_url has a :user param the username will be the one specified in the URL,
|
||||
// otherwise it will fallback to extract the username from the host header.
|
||||
module.exports.base_url = '(?:/api/:version|/u/:user/api/:version)';
|
||||
module.exports.base_url = '(?:/api/:version|/user/:user/api/:version)';
|
||||
// If useProfiler is true every response will be served with an
|
||||
// X-SQLAPI-Profile header containing elapsed timing for various
|
||||
// steps taken for producing the response.
|
||||
|
@ -147,9 +147,9 @@ test('GET /api/v1/sql with SQL parameter on SELECT only. no database param, just
|
||||
});
|
||||
});
|
||||
|
||||
test('GET /u/vizzuality/api/v1/sql with SQL parameter on SELECT only', function(done){
|
||||
test('GET /user/vizzuality/api/v1/sql with SQL parameter on SELECT only', function(done){
|
||||
assert.response(app, {
|
||||
url: '/u/vizzuality/api/v1/sql?q=SELECT%20*%20FROM%20untitle_table_4',
|
||||
url: '/user/vizzuality/api/v1/sql?q=SELECT%20*%20FROM%20untitle_table_4',
|
||||
method: 'GET'
|
||||
},{ }, function(res) {
|
||||
assert.equal(res.statusCode, 200, res.body);
|
||||
|
Loading…
Reference in New Issue
Block a user