Merge lp:~sergiusens/nuntium/smil_fix into lp:nuntium

Proposed by Sergio Schvezov
Status: Merged
Approved by: Manuel de la Peña
Approved revision: 73
Merged at revision: 51
Proposed branch: lp:~sergiusens/nuntium/smil_fix
Merge into: lp:nuntium
Prerequisite: lp:~sergiusens/nuntium/encode_decode_tests
Diff against target: 17 lines (+2/-2)
1 file modified
mms/attachments.go (+2/-2)
To merge this branch: bzr merge lp:~sergiusens/nuntium/smil_fix
Reviewer Review Type Date Requested Status
Manuel de la Peña (community) Approve
Review via email: mp+225153@code.launchpad.net

Commit message

Relaxing matching for smil media type

To post a comment you must log in.
Revision history for this message
Manuel de la Peña (mandel) :
review: Needs Fixing
lp:~sergiusens/nuntium/smil_fix updated
70. By Sergio Schvezov

Merged encode_decode_tests into smil_fix.

71. By Sergio Schvezov

Merged encode_decode_tests into smil_fix.

72. By Sergio Schvezov

Merged encode_decode_tests into smil_fix.

Revision history for this message
Sergio Schvezov (sergiusens) wrote :

Commented

lp:~sergiusens/nuntium/smil_fix updated
73. By Sergio Schvezov

Merged encode_decode_tests into smil_fix.

Revision history for this message
Manuel de la Peña (mandel) :
review: Approve
lp:~sergiusens/nuntium/smil_fix updated
74. By Sergio Schvezov

Merged encode_decode_tests into smil_fix.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'mms/attachments.go'
2--- mms/attachments.go 2014-07-02 21:07:29 +0000
3+++ mms/attachments.go 2014-07-02 21:07:29 +0000
4@@ -102,11 +102,11 @@
5 //GetSmil returns the text corresponding to the ContentType that holds the SMIL
6 func (pdu *MRetrieveConf) GetSmil() (string, error) {
7 for i := range pdu.Attachments {
8- if pdu.Attachments[i].MediaType == "application/smil" {
9+ if strings.HasPrefix(pdu.Attachments[i].MediaType, "application/smil") {
10 return string(pdu.Attachments[i].Data), nil
11 }
12 }
13- return "", errors.New("Cannot find SMIL data part")
14+ return "", errors.New("cannot find SMIL data part")
15 }
16
17 //GetDataParts returns the non SMIL ContentType data parts

Subscribers

People subscribed via source and target branches