Do not set dns config if null

This commit is contained in:
Girish Ramakrishnan
2015-10-27 12:41:13 -07:00
parent dc18a18248
commit d1e46be8ad

View File

@@ -218,6 +218,11 @@ app.controller('FinishController', ['$scope', '$location', 'Wizard', 'Client', f
Client.changeCloudronAvatar($scope.wizard.avatarBlob, function (error) {
if (error) return console.error('Unable to set avatar.', error);
if ($scope.wizard.dnsConfig === null) {
window.location.href = '/';
return;
}
Client.setDnsConfig($scope.wizard.dnsConfig, function (error) {
if (error) return console.error('Unable to set dns config.', error);