package convertor import ( "sort" "strings" "management/internal/pkg/sliceutil" ) func HandleParentPath(parentPath string) string { parentPath = strings.ReplaceAll(parentPath, ",,", ",") paths := sliceutil.RemoveDuplicatesWithMap(strings.Split(parentPath, ",")) sort.Strings(paths) parentPath = strings.Join(paths, ",") + "," return parentPath }