Poprawki w wyszikiwaniu kanałów i wyświetlaniu
This commit is contained in:
@@ -14,7 +14,7 @@ export function GET({ url }) {
|
||||
const q = (url.searchParams.get("q") || "").trim();
|
||||
const limit = clamp(Number(url.searchParams.get("limit") || 50), 1, 200);
|
||||
|
||||
if (q.length < 2) {
|
||||
if (q.length < 0) {
|
||||
return new Response(JSON.stringify({ ok: true, data: [] }), {
|
||||
status: 200,
|
||||
headers: { "Content-Type": "application/json; charset=utf-8" },
|
||||
@@ -27,9 +27,6 @@ export function GET({ url }) {
|
||||
const db = getDb();
|
||||
|
||||
try {
|
||||
// ✅ 1 rekord na kanał (grupujemy po name+logo_url)
|
||||
// ✅ pakiety zbieramy do jednego pola packages_blob
|
||||
// UWAGA: zakładam, że jambox_base_packages ma kolumnę "name"
|
||||
const rows = db
|
||||
.prepare(
|
||||
`
|
||||
|
||||
Reference in New Issue
Block a user