@ -225,6 +225,8 @@ public class DeviceInformationManagerImpl implements DeviceInformationManager {
throw new DeviceDetailsMgtException("SQL error occurred while retrieving device from database.", e);
} catch (DeviceDetailsMgtDAOException e) {
throw new DeviceDetailsMgtException("Exception occurred while retrieving device locations.", e);
} finally{
DeviceManagementDAOFactory.closeConnection();
}
@ -245,7 +245,7 @@ public class FeatureManagerImpl implements FeatureManager {
@Override
public List<ProfileFeature> getFeaturesForProfile(int profileId) throws FeatureManagementException {
try {
DeviceManagementDAOFactory.openConnection();
PolicyManagementDAOFactory.openConnection();
return featureDAO.getFeaturesForProfile(profileId);
} catch (FeatureManagerDAOException e) {
throw new FeatureManagementException("Error occurred while getting the features", e);