takeFirst will take the first non-empty value.
(values ...Value)
| 2147 | |
| 2148 | // takeFirst will take the first non-empty value. |
| 2149 | func takeFirst[Value comparable](values ...Value) Value { |
| 2150 | var empty Value |
| 2151 | return takeFirstF(values, func(v Value) bool { |
| 2152 | return v != empty |
| 2153 | }) |
| 2154 | } |
| 2155 | |
| 2156 | func newCryptoKeySecret(feature database.CryptoKeyFeature) (string, error) { |
| 2157 | switch feature { |
no test coverage detected