Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,8 @@
import org.apache.commons.collections.CollectionUtils;
import org.apache.commons.collections.MapUtils;
import org.apache.commons.lang3.BooleanUtils;
import org.apache.commons.lang3.StringUtils;

import org.apache.log4j.Logger;

import com.cloud.agent.api.LogLevel;
import com.cloud.event.EventTypes;
Expand All @@ -74,6 +75,7 @@
import com.cloud.uservm.UserVm;
import com.cloud.utils.net.Dhcp;
import com.cloud.utils.net.NetUtils;
import com.cloud.utils.StringUtils;
import com.cloud.vm.VirtualMachine;
import com.cloud.vm.VmDetailConstants;

Expand Down Expand Up @@ -298,6 +300,9 @@ public String getDeploymentPlanner() {
}

public String getDisplayName() {
if (StringUtils.isEmpty(displayName)) {
displayName = name;
}
return displayName;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
import java.util.List;
import java.util.Map;

import com.cloud.utils.StringUtils;
import com.cloud.utils.exception.CloudRuntimeException;

import org.apache.cloudstack.api.ApiArgValidator;
Expand Down Expand Up @@ -159,6 +160,9 @@ public class UpdateVMCmd extends BaseCustomIdCmd implements SecurityGroupAction,
/////////////////////////////////////////////////////

public String getDisplayName() {
if (StringUtils.isBlank(displayName)) {
displayName = name;
}
return displayName;
}

Expand Down
Loading