From da1a44d9fd4f0e036d282354c61635922f2ee837 Mon Sep 17 00:00:00 2001 From: Will Budicm Date: Mon, 31 Aug 2020 14:21:38 +1000 Subject: [PATCH] temp table drop if found. --- htdocs/cgi-bin/login_ctr.cgi | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/htdocs/cgi-bin/login_ctr.cgi b/htdocs/cgi-bin/login_ctr.cgi index 2a52717..ef4f4fd 100755 --- a/htdocs/cgi-bin/login_ctr.cgi +++ b/htdocs/cgi-bin/login_ctr.cgi @@ -207,7 +207,9 @@ sub checkCreateTables { my $hasNotesTbl = $curr_tables{'NOTES'}; my @annons = Settings::anons(); LifeLogException -> throw("Annons!") if (@annons==0);#We even added above the backup_enabled anon, so WTF? - + if($curr_tables{'life_log_temp_table'}){#A possible of some old migration lingering... + $db->do('DROP TABLE `life_log_temp_table`;'); + } # Reflect anons to db config. $sql = "SELECT ID, NAME, VALUE FROM CONFIG WHERE"; foreach my $ana(@annons){$sql .= " NAME LIKE '$ana' OR";};$sql =~ s/OR$//; $sql .=';'; -- 2.34.1