Fix automatic titles for photos without location
Signed-off-by: Michael Mayer <michael@liquidbytes.net>
This commit is contained in:
parent
f07064c2c3
commit
d2d3f7eb52
1 changed files with 1 additions and 1 deletions
|
@ -346,7 +346,7 @@ func (m *Photo) UpdateTitle(labels classify.Labels) error {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if m.NoTitle() {
|
if !hasLocation || m.NoTitle() {
|
||||||
if len(labels) > 0 && labels[0].Priority >= -1 && labels[0].Uncertainty <= 85 && labels[0].Name != "" {
|
if len(labels) > 0 && labels[0].Priority >= -1 && labels[0].Uncertainty <= 85 && labels[0].Name != "" {
|
||||||
m.PhotoTitle = fmt.Sprintf("%s / %s", txt.Title(labels[0].Name), m.TakenAt.Format("2006"))
|
m.PhotoTitle = fmt.Sprintf("%s / %s", txt.Title(labels[0].Name), m.TakenAt.Format("2006"))
|
||||||
} else if !m.TakenAtLocal.IsZero() {
|
} else if !m.TakenAtLocal.IsZero() {
|
||||||
|
|
Loading…
Reference in a new issue