natureco-cli 5.6.38 → 5.6.39

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "natureco-cli",
3
- "version": "5.6.38",
3
+ "version": "5.6.39",
4
4
  "description": "OpenClaw'dan daha güvenli, daha hızlı, daha ucuz AI agent CLI. Multi-agent, self-evolving skills, audit log, maliyet optimizasyonu ve NatureCo platform-native.",
5
5
  "bin": {
6
6
  "natureco": "bin/natureco.js"
@@ -1482,14 +1482,25 @@ async function processImessageMessage(msg, config) {
1482
1482
  if (msg.id && msg.id === imessageLastMessageId) return;
1483
1483
  if (msg.id) imessageLastMessageId = msg.id;
1484
1484
 
1485
- // Skip outgoing messages (from us)
1486
- if (msg.is_from_me || msg.from_me) return;
1485
+ // v5.6.39: Skip outgoing messages - TÜM olası field adlarını kontrol et
1486
+ // imsg history kullanırsa is_from_me, watch kullanırsa fromMe/isFromMe olabilir
1487
+ if (msg.is_from_me || msg.isFromMe || msg.from_me || msg.fromMe) {
1488
+ log('imessage', `Skipping own message (is_from_me=${msg.is_from_me || msg.from_me || msg.fromMe})`, 'gray');
1489
+ return;
1490
+ }
1487
1491
 
1488
- const sender = msg.sender || msg.from || msg.address || '';
1489
- const text = msg.text || msg.message || '';
1492
+ // v5.6.39: Sender kontrolü - sender kendimiz (bot) ise yut
1493
+ // 'sender' alanı kendi numaramız ise skip
1494
+ const myNumber = config.imessageBotId || ''; // bot ID değilse boş
1495
+ const sender = msg.sender || msg.from || msg.address || msg.handle || '';
1496
+
1497
+ const text = msg.text || msg.message || msg.body || '';
1490
1498
 
1491
1499
  if (!text.trim() || !sender) return;
1492
1500
 
1501
+ // Boş sender veya placeholder ise skip
1502
+ if (sender === 'me' || sender === 'self') return;
1503
+
1493
1504
  log('imessage', `Inbound from ${sender}: "${text.slice(0, 80)}"`, 'cyan');
1494
1505
 
1495
1506
  const { sendMessage } = require('../utils/api');