mirror of
https://github.com/vishalxl/nostr_console.git
synced 2025-10-09 19:02:35 +02:00
printed 8 bytes of hex event id
This commit is contained in:
@@ -183,7 +183,7 @@ bool gShowLnInvoicesAsQr = false;
|
||||
const int gMinWidthForLnQr = 140;
|
||||
|
||||
// event length printed
|
||||
const int gEventLenPrinted = 6;
|
||||
const int gEventLenPrinted = 8;
|
||||
|
||||
// used in word/event search
|
||||
const int gMinEventIdLenInSearch = gEventLenPrinted;
|
||||
|
@@ -2957,7 +2957,6 @@ int sortTreeByItsTime(Tree a, Tree b) {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* @function getTree Creates a Tree out of these received List of events.
|
||||
* Will remove duplicate events( which should not ideally exists because we have a set),
|
||||
@@ -2982,19 +2981,11 @@ Store getTree(Set<Event> events) {
|
||||
events.removeWhere( (event) => !Store.typesInEventMap.contains(event.eventData.kind));
|
||||
|
||||
// remove duplicate events
|
||||
Set ids = {};
|
||||
Set<String> ids = {};
|
||||
events.retainWhere((event) => ids.add(event.eventData.id));
|
||||
|
||||
// process kind 0 events about metadata
|
||||
/* for (var event in events) {
|
||||
processKind0Event(event);
|
||||
}
|
||||
*/
|
||||
|
||||
ids.clear();
|
||||
print("before kind 0 : ${events.length}");
|
||||
events.retainWhere((event) => processKind0Event(event) != 3 );
|
||||
print("after kind 0 : ${events.length}");
|
||||
|
||||
// process kind 3 events which is contact list. Update global info about the user (with meta data)
|
||||
for (var event in events) {
|
||||
|
Reference in New Issue
Block a user