chore(search): trim the live photo comments

This commit is contained in:
Dominik Schmidt committed 2026-09-03 03:34:33 +02:00
1 parent 0a4f3ed786
commit 5995938c34
2 files changed
+4 -9

No files matched your search

@@ -8,12 +8,10 @@ import (
)
func (t Tika) getLivePhoto(meta map[string][]string) *libregraph.LivePhoto {
// ContentId pairs the two halves and is what makes it a live photo, so without
// it there is no facet. The video exposes it via the QuickTime item list; the
// still image carries it in the Apple maker note (tag 0x0011), which tika
// surfaces generically under "Content Identifier" (the HEIC maker note is
// parsed since metadata-extractor 2.21.0). A file is only ever one half, so
// reading both keys covers both.
// ContentId pairs the two halves, without it there is no live photo. The
// video carries it in the QuickTime item list, the still image in the Apple
// maker note, which tika surfaces as "Content Identifier". A file is only
// ever one half, so both keys are read.
contentID, err := getFirstValue(meta, "com.apple.quicktime.content.identifier", "Content Identifier")
if err != nil || contentID == "" {
return nil
@@ -26,9 +26,6 @@ var _ = Describe("getLivePhoto", func() {
})
It("maps the still half via the Apple maker-note content identifier", func() {
// the still carries the pairing id in the Apple maker note, which tika
// surfaces under "Content Identifier" (HEIC maker note parsed since
// metadata-extractor 2.21.0, drewnoakes/metadata-extractor#739).
livePhoto := Tika{}.getLivePhoto(map[string][]string{
"Content-Type": {"image/heic"},
"Content Identifier": {"6F1A2B3C-1234-4E5F-9A8B-0011223344CC"},