mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 10:43:20 +00:00
Merge resolution, master into dev.
This commit is contained in:
@@ -15,9 +15,8 @@
|
||||
|
||||
// Run all strings to be used in an SQL query through this proc first to properly escape out injection attempts.
|
||||
/proc/sanitizeSQL(var/t as text)
|
||||
var/sanitized_text = replacetext(t, "'", "\\'")
|
||||
sanitized_text = replacetext(sanitized_text, "\"", "\\\"")
|
||||
return sanitized_text
|
||||
var/sqltext = dbcon.Quote(t);
|
||||
return copytext(sqltext, 2, lentext(sqltext)-1);//Quote() adds quotes around input, we already do that
|
||||
|
||||
/*
|
||||
* Text sanitization
|
||||
@@ -314,4 +313,4 @@ proc/TextPreview(var/string,var/len=40)
|
||||
else
|
||||
return string
|
||||
else
|
||||
return "[copytext(string, 1, 37)]..."
|
||||
return "[copytext(string, 1, 37)]..."
|
||||
|
||||
Reference in New Issue
Block a user