fmt2
All checks were successful
Deploy on push / deploy (push) Successful in 5m34s

This commit is contained in:
2025-08-30 17:07:37 +03:00
parent 1ad4b9118e
commit f6253f2007

View File

@@ -27,7 +27,8 @@ def get_entity_field_name(entity_type: str) -> str:
"""Возвращает имя поля для связи с сущностью в модели подписчика""" """Возвращает имя поля для связи с сущностью в модели подписчика"""
entity_field_mapping = {"author": "following", "topic": "topic", "community": "community", "shout": "shout"} entity_field_mapping = {"author": "following", "topic": "topic", "community": "community", "shout": "shout"}
if entity_type not in entity_field_mapping: if entity_type not in entity_field_mapping:
raise ValueError(f"Unknown entity_type: {entity_type}") msg = f"Unknown entity_type: {entity_type}"
raise ValueError(msg)
return entity_field_mapping[entity_type] return entity_field_mapping[entity_type]