Moved the message HTML parsing from PHP to JavaScript

Now we can properly parse PGP/MIME HTML messages
This commit is contained in:
the-djmaze 2022-02-02 13:02:48 +01:00
parent 3615405aac
commit e265a0f1c1
13 changed files with 563 additions and 837 deletions

View file

@ -32,7 +32,7 @@ export class AttachmentCollectionModel extends AbstractCollectionModel
* @returns {*}
*/
findByCid(cid) {
let regex = /^<+|>+$/g, cidc = cid.replace(regex, '');
return this.find(item => cid === item.cid || cidc === item.cid || cidc === item.cid.replace(regex, ''));
cid = cid.replace(/^<+|>+$/g, '');
return this.find(item => cid === item.contentId());
}
}