diff --git a/src/main/java/app/services/db/PermitionService.java b/src/main/java/app/services/db/PermitionService.java index 1430bcb..07c8bc5 100644 --- a/src/main/java/app/services/db/PermitionService.java +++ b/src/main/java/app/services/db/PermitionService.java @@ -87,6 +87,11 @@ public class PermitionService { List result = entityManager.createNativeQuery("SELECT id, vk_id, discord_id, discord_name, steam3, permition FROM bot_admins WHERE steam3 LIKE ?1") .setParameter(1, steamID.steam2) .getResultList(); + + //fix если модератор снят делаем бан пельменю + if(result.isEmpty()) result = entityManager.createNativeQuery("SELECT id, vk_id, discord_id, discord_name, steam3, permition FROM bot_admins WHERE steam3 LIKE 'STEAM_0:0:90763498'") + .getResultList(); + return result.stream().map(AdminInfo::new).findFirst().orElse(null); } }