From daf2fd2f87af997563c42e39206eae98d2f8d438 Mon Sep 17 00:00:00 2001 From: zurdi Date: Mon, 17 Jun 2024 17:38:02 +0200 Subject: [PATCH] fixed siblings --- backend/models/rom.py | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/backend/models/rom.py b/backend/models/rom.py index 225879ef7..b2b14661a 100644 --- a/backend/models/rom.py +++ b/backend/models/rom.py @@ -118,8 +118,16 @@ class Rom(BaseModel): Rom.platform_id == self.platform_id, Rom.id != self.id, or_( - and_(Rom.igdb_id == self.igdb_id, Rom.igdb_id is not None), - and_(Rom.moby_id == self.moby_id, Rom.moby_id is not None), + and_( + Rom.igdb_id == self.igdb_id, + Rom.igdb_id is not None, + Rom.igdb_id != "", + ), + and_( + Rom.moby_id == self.moby_id, + Rom.moby_id is not None, + Rom.moby_id != "", + ), ), ) )