try disabling alreadyHave check

This commit is contained in:
Martti Malmi 2024-01-06 00:52:24 +02:00
parent 39f4ee9c2b
commit 1aadda1c6b
2 changed files with 3 additions and 2 deletions

View File

@ -35,6 +35,7 @@
"eventLinkPrefix": "note",
"profileLinkPrefix": "npub",
"defaultRelays": {
"ws://localhost:7777": { "read": true, "write": true },
"wss://relay.snort.social/": { "read": true, "write": true },
"wss://nostr.wine/": { "read": true, "write": false },
"wss://eden.nostr.land/": { "read": true, "write": false },

View File

@ -9,8 +9,6 @@ import { ConnectionStats } from "./connection-stats";
import { NostrEvent, ReqCommand, ReqFilter, TaggedNostrEvent, u256 } from "./nostr";
import { RelayInfo } from "./relay-info";
import EventKind from "./event-kind";
import { getHex64 } from "./utils";
import inMemoryDB from "./InMemoryDB";
/**
* Relay settings
@ -202,11 +200,13 @@ export class Connection extends EventEmitter<ConnectionEvents> {
this.#activity = unixNowMs();
if ((e.data as string).length > 0) {
// skip message processing if we've already seen it
/* there's some problem in retrieval from inMemoryDB? try disabling for now
const msgId = getHex64(e.data as string, "id");
if (inMemoryDB.has(msgId)) {
console.log("already have");
return;
}
*/
const msg = JSON.parse(e.data as string) as Array<string | NostrEvent | boolean>;
const tag = msg[0] as string;