From 5bf5e95c8bee3a36516199f0e8628ec2b021c2dd Mon Sep 17 00:00:00 2001 From: Hamza-Ayed Date: Fri, 5 Jun 2026 12:29:51 +0300 Subject: [PATCH] Deploy on 2026-06-05 12:29:51 --- database/seeds/SourceSeeder.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/database/seeds/SourceSeeder.php b/database/seeds/SourceSeeder.php index 94975f6..c069509 100644 --- a/database/seeds/SourceSeeder.php +++ b/database/seeds/SourceSeeder.php @@ -39,7 +39,7 @@ class SourceSeeder // Insert categories if (!empty($source['categories'])) { foreach ($source['categories'] as $category) { - $stmt = $this->pdo->prepare("SELECT id FROM source_categories WHERE source_id = ? AND category = ?"); + $stmt = $this->pdo->prepare("SELECT source_id FROM source_categories WHERE source_id = ? AND category = ?"); $stmt->execute([$sourceId, $category]); if (!$stmt->fetch()) { $stmt = $this->pdo->prepare("INSERT INTO source_categories (source_id, category) VALUES (?, ?)"); @@ -53,7 +53,7 @@ class SourceSeeder // Update existing source with new priority/categories if needed if (!empty($source['categories'])) { foreach ($source['categories'] as $category) { - $stmt = $this->pdo->prepare("SELECT id FROM source_categories WHERE source_id = ? AND category = ?"); + $stmt = $this->pdo->prepare("SELECT source_id FROM source_categories WHERE source_id = ? AND category = ?"); $stmt->execute([$existingId, $category]); if (!$stmt->fetch()) { $stmt = $this->pdo->prepare("INSERT INTO source_categories (source_id, category) VALUES (?, ?)");