Skip to content

Commit

Permalink
flix playlist cant writem4a
Browse files Browse the repository at this point in the history
  • Loading branch information
zhaarey committed May 6, 2024
1 parent 0d4f173 commit 578003a
Showing 1 changed file with 11 additions and 9 deletions.
20 changes: 11 additions & 9 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -787,15 +787,17 @@ func writeM4a(w *mp4.Writer, info *SongInfo, meta *AutoGenerated, data []byte, t
if err != nil {
return err
}

plID, err := strconv.ParseUint(meta.Data[0].ID, 10, 32)
if err != nil {
return err
}

err = addMeta(mp4.BoxType{'p', 'l', 'I', 'D'}, uint32(plID))
if err != nil {
return err

if !strings.Contains(meta.Data[0].ID, "pl."){
plID, err := strconv.ParseUint(meta.Data[0].ID, 10, 32)
if err != nil {
return err
}

err = addMeta(mp4.BoxType{'p', 'l', 'I', 'D'}, uint32(plID))
if err != nil {
return err
}
}
}

Expand Down

0 comments on commit 578003a

Please sign in to comment.