-
Notifications
You must be signed in to change notification settings - Fork 303
Open
Description
The interface is implemented by OCA\Mail\Model\Message and OCA\Mail\Model\IMAPMessage.
Lines 119 to 122 in 52214dc
| /** | |
| * @return Horde_Mime_Part[] | |
| */ | |
| public function getAttachments(): array; |
OCA\Mail\Model\Message is okay:
Lines 291 to 305 in 52214dc
| /** | |
| * @param string $name | |
| * @param string $content | |
| * @param string $mime | |
| * @return void | |
| */ | |
| private function createAttachmentDetails(string $name, string $content, string $mime): void { | |
| $part = new Horde_Mime_Part(); | |
| $part->setCharset('us-ascii'); | |
| $part->setDisposition('attachment'); | |
| $part->setName($name); | |
| $part->setContents($content); | |
| $part->setType($mime); | |
| $this->attachments[] = $part; | |
| } |
OCA\Mail\Model\IMAPMessage is not:
mail/lib/Model/IMAPMessage.php
Lines 385 to 391 in 52214dc
| /** | |
| * @return Horde_Mime_Part[] | |
| */ | |
| #[\Override] | |
| public function getAttachments(): array { | |
| return $this->attachments; | |
| } |
mail/lib/IMAP/ImapMessageFetcher.php
Lines 304 to 312 in 52214dc
| $this->attachments[] = [ | |
| 'id' => $p->getMimeId(), | |
| 'messageId' => $this->uid, | |
| 'fileName' => $p->getName(), | |
| 'mime' => $p->getType(), | |
| 'size' => $p->getBytes(), | |
| 'cid' => $p->getContentId(), | |
| 'disposition' => $p->getDisposition() | |
| ]; |
mail/lib/IMAP/ImapMessageFetcher.php
Lines 337 to 345 in 52214dc
| $this->attachments[] = [ | |
| 'id' => $p->getMimeId(), | |
| 'messageId' => $this->uid, | |
| 'fileName' => $p->getName(), | |
| 'mime' => $p->getType(), | |
| 'size' => $p->getBytes(), | |
| 'cid' => $p->getContentId(), | |
| 'disposition' => $p->getDisposition() | |
| ]; |
Solution
Drop the interface?
It looks like we are always using the actual classes instead of the interface.
Reactions are currently unavailable