// }
// return applicationVersionModels;
// }
private DomainStatisticsModel getDomainStatisticsModel(Organization organization) {
DomainStatisticsModel domainStatisticsModel = new DomainStatisticsModel();
domainStatisticsModel.setTotalApplications(organization != null ? organizationService.countOrganizationApps(organization.getId()) : 0);
domainStatisticsModel.setTotalApplicationVersions(organization != null ? organizationService.countOrganizationAppVersions(organization.getId()) : 0);
domainStatisticsModel.setTotalUsers(organization != null ? organizationService.countOrganizationUsers(organization.getId(), true) : 0);
domainStatisticsModel.setTotalPendingInvitations(organization != null ? invitationService.countAllForOrganizationIncludingGroups(organization.getId()) : 0);
domainStatisticsModel.setTotalMegabyteStorageAmount(organizationService.getTotalMegabyteStorageAmount(organization));
domainStatisticsModel.setTotalMegabyteBandwidthUsed(organization != null ? bandwidthService.getMegabyteBandwidthUsed(organization.getId()) : 0);
return domainStatisticsModel;
}