Opened 3 years ago
Closed 3 years ago
#1486683 closed Feature Patches (fixed)
Patch for vcard_attachments
| Reported by: | dziobak | Owned by: | |
|---|---|---|---|
| Priority: | 5 | Milestone: | 0.4-stable |
| Component: | Plugins | Version: | git-master |
| Severity: | normal | Keywords: | vcard message |
| Cc: |
Description
This function detect not only vcard attachment ('content-type: text/vcard') but also message as 'content-type: text/vcard'.
Tis function is a modified Rosali's function to detect text/calendar message.
30 function message_load($p)
31 {
32 $this->message = $p['object'];
33
34 foreach ($this->message->parts as $pid => $part) {
35 $mimetype = strtolower($part->ctype_primary . '/' . $part->ctype_secondary);
36 if($mimetype == 'text/vcard'){
37 $this->vcard_part = $part->mime_id;
38 if ($this->vcard_part)
39 $this->add_texts('localization');
40 return $p;
41 }
42 }
43 foreach ((array)$this->message->attachments as $attachment) {
44 if (in_array($attachment->mimetype, array('text/vcard', 'text/x-vcard')))
45 $this->vcard_part = $attachment->mime_id;
46 if ($this->vcard_part)
47 $this->add_texts('localization');
48 return $p;
49 }
50 }
Change History (1)
comment:1 Changed 3 years ago by alec
- Resolution set to fixed
- Status changed from new to closed
Note: See
TracTickets for help on using
tickets.

Fixed in r3571/svn.