mirror of
https://github.com/believethehype/nostrdvm.git
synced 2025-06-20 11:21:07 +02:00
fix users tag in search
This commit is contained in:
parent
b68c4a4b42
commit
acb59168d5
@ -110,7 +110,9 @@ class AdvancedSearch(DVMTaskInterface):
|
|||||||
search_until = Timestamp.from_secs(int(options["until"]))
|
search_until = Timestamp.from_secs(int(options["until"]))
|
||||||
userkeys = []
|
userkeys = []
|
||||||
for user in options["users"]:
|
for user in options["users"]:
|
||||||
user = user[1]
|
tag = Tag.parse(user)
|
||||||
|
user = tag.as_vec()[1]
|
||||||
|
#user = user[1]
|
||||||
user = str(user).lstrip("@")
|
user = str(user).lstrip("@")
|
||||||
if str(user).startswith('npub'):
|
if str(user).startswith('npub'):
|
||||||
userkey = PublicKey.from_bech32(user)
|
userkey = PublicKey.from_bech32(user)
|
||||||
|
@ -91,7 +91,8 @@ class AdvancedSearchWine(DVMTaskInterface):
|
|||||||
options = DVMTaskInterface.set_options(request_form)
|
options = DVMTaskInterface.set_options(request_form)
|
||||||
userkeys = []
|
userkeys = []
|
||||||
for user in options["users"]:
|
for user in options["users"]:
|
||||||
user = user[1]
|
tag = Tag.parse(user)
|
||||||
|
user = tag.as_vec()[1]
|
||||||
user = str(user).lstrip("@")
|
user = str(user).lstrip("@")
|
||||||
if str(user).startswith('npub'):
|
if str(user).startswith('npub'):
|
||||||
userkey = PublicKey.from_bech32(user)
|
userkey = PublicKey.from_bech32(user)
|
||||||
|
@ -66,8 +66,9 @@ class DiscoverNonFollowers(DVMTaskInterface):
|
|||||||
keys = Keys.from_sk_str(sk.to_hex())
|
keys = Keys.from_sk_str(sk.to_hex())
|
||||||
signer = ClientSigner.keys(keys)
|
signer = ClientSigner.keys(keys)
|
||||||
cli = Client.with_opts(signer, opts)
|
cli = Client.with_opts(signer, opts)
|
||||||
for relay in self.dvm_config.RELAY_LIST:
|
cli.add_relay("wss://relay.nostr.band")
|
||||||
cli.add_relay(relay)
|
#for relay in self.dvm_config.RELAY_LIST:
|
||||||
|
# cli.add_relay(relay)
|
||||||
cli.connect()
|
cli.connect()
|
||||||
|
|
||||||
options = DVMTaskInterface.set_options(request_form)
|
options = DVMTaskInterface.set_options(request_form)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user