(values map[string]interface{}, fallback string, accountID string)
| 1496 | } |
| 1497 | |
| 1498 | func extractDisplayName(values map[string]interface{}, fallback string, accountID string) string { |
| 1499 | name := extractStringValue(values["name"]) |
| 1500 | if name != "" { |
| 1501 | return name |
| 1502 | } |
| 1503 | if fallback != "" { |
| 1504 | return fallback |
| 1505 | } |
| 1506 | if accountID == "default" { |
| 1507 | return "Default" |
| 1508 | } |
| 1509 | return accountID |
| 1510 | } |
| 1511 | |
| 1512 | func normalizeDefaultAccount(defaultAccount string, accountIDs []string) string { |
| 1513 | if len(accountIDs) == 0 { |
no test coverage detected