return _lastUsedMrid;
}
public void promoteModuleDescriptorVisibility(String mdId, String visibility) {
LOGGER.debug("Asking promotion of module: " + mdId + " to " + visibility);
Visibility newVisibility = Visibility.fromString(visibility);
ModuleDescriptorDao dao = WOJServer.getInstance().getDataService().getModuleDescriptorDao();
ModuleDescriptor md = dao.getModule(mdId);
Visibility oldVisibility = md.getVisibility();
Long oldAccessorId = md.getAccessorId();
if (oldVisibility != Visibility.SANDBOX) {
String msg = md.getModuleInfoAsString() + "cannot be promoted it's not in SANDBOX visibility, it may already have been promoted";
LOGGER.warn(msg);
throw new IllegalArgumentException(msg);