fix: send fewer items to client-side for ACP settings/email page

v1.18.x
Julian Lam 4 years ago
parent c079051b19
commit 438fa5c88f

@ -22,7 +22,7 @@ settingsController.email = async (req, res) => {
res.render('admin/settings/email', {
emails: emails,
sendable: emails.filter(e => !e.path.includes('_plaintext') && !e.path.includes('partials')),
sendable: emails.filter(e => !e.path.includes('_plaintext') && !e.path.includes('partials')).map(tpl => tpl.path),
services: emailer.listServices(),
});
};

@ -121,7 +121,7 @@
<label>[[admin/settings/email:testing.select]]</label>
<select id="test-email" class="form-control">
<!-- BEGIN sendable -->
<option value="{sendable.path}">{sendable.path}</option>
<option value="{@value}">{@value}</option>
<!-- END sendable -->
</select>
</div>

Loading…
Cancel
Save