/
githubmirror
/
photoprism
Обзор
Документация
Войти
/
githubmirror
/
photoprism
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
develop
internal/entity/string_keyvalue.go
21 строка
409 B
Michael Mayer
People: Show real name instead of uid in logs #1438 #2182
04 апр 2022, 15:21
04 апр 2022, 15:21
c74fcbf
Код
Авторство
О чём код?
package entity // KeyValue represents a string key/value pair. type KeyValue struct { K string `json:"value"` V string `json:"text"` } // KeyValues represents a list of string key/value pairs. type KeyValues []KeyValue // Strings returns the list as a lookup map. func (v KeyValues) Strings() Strings { result := make(Strings, len(v)) for i := range v { result[v[i].K] = v[i].V } return result }