use constants for admin location

This commit is contained in:
Girish Ramakrishnan
2017-05-24 15:40:16 -07:00
parent 35a2a656d3
commit 11697f11cf
3 changed files with 6 additions and 3 deletions
+2 -1
View File
@@ -13,6 +13,7 @@ exports = module.exports = {
var assert = require('assert'),
AWS = require('aws-sdk'),
constants = require('../constants.js'),
debug = require('debug')('box:dns/route53'),
dns = require('native-dns'),
SubdomainError = require('../subdomains.js').SubdomainError,
@@ -245,7 +246,7 @@ function verifyDnsConfig(dnsConfig, domain, ip, callback) {
return callback(new SubdomainError(SubdomainError.BAD_FIELD, 'Domain nameservers are not set to Route53'));
}
upsert(credentials, domain, 'my', 'A', [ ip ], function (error, changeId) {
upsert(credentials, domain, constants.ADMIN_LOCATION, 'A', [ ip ], function (error, changeId) {
if (error) return callback(error);
debug('verifyDnsConfig: A record added with change id %s', changeId);