fix: server expiration LEFT JOIN and Steam Workshop MySQL 5.7 safe migration
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/fca65480-29f6-4a76-ae4f-442477782a2c Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
This commit is contained in:
parent
7016b79805
commit
6e424bee60
3 changed files with 123 additions and 31 deletions
|
|
@ -207,6 +207,18 @@ function update_module($db, $module_id, $module)
|
|||
{
|
||||
foreach ((array)$install_queries[$i+1] as $query)
|
||||
{
|
||||
// Support PHP callables in addition to plain SQL strings.
|
||||
// A callable receives $db as its only argument and must return
|
||||
// true on success or false on failure.
|
||||
if (is_callable($query))
|
||||
{
|
||||
if ( $query($db) )
|
||||
continue;
|
||||
|
||||
print_failure("".get_lang("query_failed")." (callable migration step) ".get_lang("query_failed_2")."");
|
||||
return -2;
|
||||
}
|
||||
|
||||
if ( $db->query($query) )
|
||||
continue;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue