Nuage VSP : Fix for NPE while cleaning up account when there are still resources belonging to that account

This commit is contained in:
Nick Livens 2016-05-02 10:16:21 +02:00
parent 4b6179940d
commit d862a09771

View File

@ -109,7 +109,9 @@ public class NuageVspEntityBuilder {
vspNetworkBuilder.domain(vspDomain);
AccountVO account = _accountDao.findById(network.getAccountId());
vspNetworkBuilder.accountUuid(account.getUuid()).accountName(account.getAccountName());
if (account != null) {
vspNetworkBuilder.accountUuid(account.getUuid()).accountName(account.getAccountName());
}
NetworkOfferingVO networkOffering = _networkOfferingDao.findById(network.getNetworkOfferingId());
vspNetworkBuilder.egressDefaultPolicy(networkOffering.getEgressDefaultPolicy());