Do not force ending dot in SQL-API hostname, for easier testing

This commit is contained in:
Sandro Santilli
2013-11-12 17:41:10 +01:00
parent eb9dfed731
commit 2897c0c8bf
2 changed files with 4 additions and 1 deletions
+3 -1
View File
@@ -67,7 +67,9 @@ module.exports = function(){
var api = global.environment.sqlapi;
// build up api string
var sqlapi = api.protocol + '://' + username + '.' + api.domain + ':' + api.port + '/api/' + api.version + '/sql'
var sqlapi = api.protocol + '://' + username;
if ( api.domain ) sqlapi += '.' + api.domain;
sqlapi += ':' + api.port + '/api/' + api.version + '/sql'
var qs = { q: sql }