Copy Engine: scrub en dashes too

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
martbost
2026-09-14 06:44:11 -05:00
parent c1f58b2acf
commit 0f030a4943
+1 -1
View File
@@ -82,7 +82,7 @@ function complete(messages) {
req.on('error', reject); req.on('timeout', () => req.destroy(new Error('engine timeout'))); req.end(body); req.on('error', reject); req.on('timeout', () => req.destroy(new Error('engine timeout'))); req.end(body);
}); });
} }
const scrub = t => String(t || '').replace(/—|--/g, ',').replace(/^["“]+|["”]+$/g, '').trim(); const scrub = t => String(t || '').replace(/\s*[—–]\s*|\s*--\s*/g, ', ').replace(/^["“]+|["”]+$/g, '').trim();
async function status(email) { async function status(email) {
const acct = await R.accounts.byEmail(email); if (!acct) return { error: 'No such account.' }; const acct = await R.accounts.byEmail(email); if (!acct) return { error: 'No such account.' };