fix: Move report_cheater to flags to avoid circular import
This commit is contained in:
1 parent
3139c08c91
commit
cfcbda732d
2 files changed
+9
-8
No files matched your search
@@ -1,7 +1,14 @@
|
||||
from CTFd.plugins.flags import BaseFlag
|
||||
from CTFd.utils.user import get_current_user
|
||||
from CTFd.models import db
|
||||
from .models import CheaterTeams
|
||||
|
||||
from . import report_cheater
|
||||
|
||||
|
||||
def report_cheater(challenge_id: int, cheater_id: int, helper_id: int, flag_id: int):
|
||||
cheater = CheaterTeams(challenge_id, cheater_id, helper_id, flag_id)
|
||||
db.session.add(cheater)
|
||||
db.session.commit()
|
||||
|
||||
|
||||
class PersonalFlag(BaseFlag):
|
||||
|
||||
Reference in new issue
Block a user