mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-22 04:24:20 +01:00
Don't try to run queries when the database isn't enabled. (#24598)
This commit is contained in:
@@ -382,6 +382,8 @@ SUBSYSTEM_DEF(dbcore)
|
||||
* * log_error - Do we want to log errors this creates? Disable this if you are running sensitive queries where you dont want errors logged in plain text (EG: Auth token stuff)
|
||||
*/
|
||||
/datum/db_query/proc/warn_execute(async = TRUE, log_error = TRUE)
|
||||
if(!GLOB.configuration.database.enabled)
|
||||
return
|
||||
. = Execute(async, log_error)
|
||||
if(!.)
|
||||
SSdbcore.total_errors++
|
||||
|
||||
Reference in New Issue
Block a user