blob: 1ad4adefed5f12cde83cbb0c495bd4319f7d0a5f [file] [log] [blame]
'use strict'
var urljoin = require('url-join'),
ok = require('objectkit'),
config = require('../config.json')
function buildUrl(opts) {
return urljoin(
ok(config).getIfExists('usergrid.baseUrl'),
opts.client.orgId,
opts.client.appId,
opts.type, (typeof opts.uuidOrName === 'string') ? opts.uuidOrName : ""
)
}
module.exports = buildUrl