Fix address hallucination and duplicate status messages
- answerFor returning '' (intentionally blank) was treated as falsy, falling through to AI which fabricated "123 Main Street". Now empty string skips the field without triggering AI or reporting unknown. - status.mjs was printing to stdout AND sending via Telegram, causing OpenClaw to relay a duplicate plain-text copy. Now only prints to stdout when Telegram isn't configured. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -267,9 +267,11 @@ if (jsonMode) {
|
||||
} else {
|
||||
const report = formatReport(status);
|
||||
const settings = loadConfig(resolve(__dir, 'config/settings.json'));
|
||||
// Always send via Telegram directly if configured (so markdown renders)
|
||||
// Send via Telegram directly if configured (so markdown renders)
|
||||
if (settings.notifications?.bot_token && settings.notifications?.telegram_user_id) {
|
||||
await sendTelegram(settings, report);
|
||||
// Don't also print to stdout — OpenClaw would relay it as a duplicate plain-text message
|
||||
} else {
|
||||
console.log(report);
|
||||
}
|
||||
console.log(report);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user