🛠️ Refactor migrations, models, configs, and Blade files to apply consistent formatting, remove unnecessary lines, and improve readability.

This commit is contained in:
HolgerHatGarKeineNode
2026-01-18 19:50:04 +01:00
parent a4aad6ebb6
commit b090336c4f
59 changed files with 246 additions and 199 deletions

View File

@@ -22,6 +22,7 @@ trait NostrFetcherTrait
'hex' => $item,
'npub' => (new Key)->convertPublicKeyToBech32($item),
]);
continue;
}
$hex->push([
@@ -30,10 +31,10 @@ trait NostrFetcherTrait
]);
}
$subscription = new Subscription();
$subscription = new Subscription;
$subscriptionId = $subscription->setId();
$filter1 = new Filter();
$filter1 = new Filter;
$filter1->setKinds([0]); // You can add multiple kind numbers
$filter1->setAuthors($hex->pluck('hex')->toArray()); // You can add multiple author ids
$filters = [$filter1];
@@ -54,7 +55,7 @@ trait NostrFetcherTrait
try {
$response = $request->send();
$data = $response[$relayUrl];
if (!empty($data)) {
if (! empty($data)) {
\Log::info('Successfully fetched data from relay: '.$relayUrl);
break; // Exit the loop if data is not empty
}
@@ -65,6 +66,7 @@ trait NostrFetcherTrait
if (empty($data)) {
\Log::warning('No data found from any relay');
return;
}
foreach ($data as $item) {
@@ -94,5 +96,4 @@ trait NostrFetcherTrait
}
}
}
}