if (monitor.isCanceled()) {
return;
}
String profileId = getIdForProfile(execution);
coveredProfiles.add(profileId);
TeaVMProfile profile = settings.getProfile(profileId);
if (profile == null) {
profile = settings.createProfile();
profile.setName(profileId);
}
profile.setExternalToolId(TOOL_ID);
configureProfile(execution, profile, new SubProgressMonitor(monitor, 1000));
if (monitor.isCanceled()) {
return;
}
}
for (TeaVMProfile profile : settings.getProfiles()) {
if (!coveredProfiles.contains(profile.getName()) && profile.getExternalToolId().equals(TOOL_ID)) {
settings.deleteProfile(profile);
}
}
settings.save();
} finally {