mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2025-12-01 21:13:04 +08:00
fix(CI/Codestyle): Minor typo in insert_delete_safety_check (#21639)
This commit is contained in:
@@ -150,7 +150,7 @@ def insert_delete_safety_check(file: io, file_path: str) -> None:
|
|||||||
if line.startswith("--"):
|
if line.startswith("--"):
|
||||||
continue
|
continue
|
||||||
if "INSERT" in line and "DELETE" not in previous_line:
|
if "INSERT" in line and "DELETE" not in previous_line:
|
||||||
print(f"❌ No DELETE keyword found before the INSERT in {file_path} at line {line_number}\nIf this error is intended, please advert a maintainer")
|
print(f"❌ No DELETE keyword found before the INSERT in {file_path} at line {line_number}\nIf this error is intended, please notify a maintainer")
|
||||||
check_failed = True
|
check_failed = True
|
||||||
previous_line = line
|
previous_line = line
|
||||||
match = re.match(r"DELETE FROM\s+`([^`]+)`", line, re.IGNORECASE)
|
match = re.match(r"DELETE FROM\s+`([^`]+)`", line, re.IGNORECASE)
|
||||||
@@ -158,7 +158,7 @@ def insert_delete_safety_check(file: io, file_path: str) -> None:
|
|||||||
table_name = match.group(1)
|
table_name = match.group(1)
|
||||||
if table_name in not_delete:
|
if table_name in not_delete:
|
||||||
print(
|
print(
|
||||||
f"❌ Entries from {table} should not be deleted! {file_path} at line {line_number}")
|
f"❌ Entries from {table_name} should not be deleted! {file_path} at line {line_number}\nIf this error is intended, please notify a maintainer")
|
||||||
check_failed = True
|
check_failed = True
|
||||||
|
|
||||||
# Handle the script error and update the result output
|
# Handle the script error and update the result output
|
||||||
|
|||||||
Reference in New Issue
Block a user