Skip to content

fix: use Database.Format for SQL escaping instead of g_hDB.Escape - #28

Open
Rushaway wants to merge 1 commit into
masterfrom
fix/sql-format-escaping
Open

fix: use Database.Format for SQL escaping instead of g_hDB.Escape#28
Rushaway wants to merge 1 commit into
masterfrom
fix/sql-format-escaping

Conversation

@Rushaway

Copy link
Copy Markdown
Member

Summary

  • Replace manual g_hDB.Escape + separate escaped buffers with Database.Format, which escapes %s string arguments directly against the query.
  • Bump version (1.DZ.4 -> 1.DZ.5).

Why

Database.Format is cleaner than a manual escape-then-format call per parameter and avoids extra driver/threading touchpoints from calling Escape directly.

Test plan

  • Compile plugin and confirm no errors
  • Trigger client/admin/other log entries with names containing quotes and confirm the DB rows insert correctly

Database.Format escapes %s arguments automatically, avoiding a manual
call+buffer per parameter and the extra driver/threading touchpoints
from calling Escape directly.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant