()
| 130 | } |
| 131 | |
| 132 | async showMailEditor() { |
| 133 | const options = {}; |
| 134 | const emailContent = this.getEmailText(this.editorType == PLAIN_TEXT ? 'text' : 'html'); |
| 135 | if (/BEGIN\sPGP\sMESSAGE/.test(emailContent)) { |
| 136 | try { |
| 137 | options.quotedMail = normalizeArmored(emailContent, /-----BEGIN PGP MESSAGE-----[\s\S]+?-----END PGP MESSAGE-----/); |
| 138 | } catch (e) { |
| 139 | options.text = emailContent; |
| 140 | } |
| 141 | } else { |
| 142 | options.text = emailContent; |
| 143 | } |
| 144 | options.recipients = await this.currentProvider.getRecipients(this.editElement); |
| 145 | this.port.emit('eframe-display-editor', options); |
| 146 | } |
| 147 | |
| 148 | getEmailText(type) { |
| 149 | let text; |
no test coverage detected