@ -19699,7 +19699,7 @@ ORDER BY
my $ variable_source_uuid = $ row - > [ 4 ] ? $ row - > [ 4 ] : "none" ;
my $ variable_source_uuid = $ row - > [ 4 ] ? $ row - > [ 4 ] : "none" ;
my $ variable_value = $ row - > [ 5 ] ;
my $ variable_value = $ row - > [ 5 ] ;
my $ modified_date = $ row - > [ 6 ] ;
my $ modified_date = $ row - > [ 6 ] ;
$ anvil - > Log - > variables ( { source = > $ THIS_FILE , line = > __LINE__ , level = > 1 , list = > {
$ anvil - > Log - > variables ( { source = > $ THIS_FILE , line = > __LINE__ , level = > $ debug , list = > {
variable_uuid = > $ variable_uuid ,
variable_uuid = > $ variable_uuid ,
variable_section = > $ variable_section ,
variable_section = > $ variable_section ,
variable_name = > $ variable_name ,
variable_name = > $ variable_name ,
@ -19712,12 +19712,12 @@ ORDER BY
if ( not $ variable_source_table )
if ( not $ variable_source_table )
{
{
$ variable_source_table = "none" ;
$ variable_source_table = "none" ;
$ anvil - > Log - > variables ( { source = > $ THIS_FILE , line = > __LINE__ , level = > 1 , list = > { variable_source_table = > $ variable_source_table } } ) ;
$ anvil - > Log - > variables ( { source = > $ THIS_FILE , line = > __LINE__ , level = > $ debug , list = > { variable_source_table = > $ variable_source_table } } ) ;
}
}
if ( not $ variable_source_uuid )
if ( not $ variable_source_uuid )
{
{
$ variable_source_uuid = "none" ;
$ variable_source_uuid = "none" ;
$ anvil - > Log - > variables ( { source = > $ THIS_FILE , line = > __LINE__ , level = > 1 , list = > { variable_source_uuid = > $ variable_source_uuid } } ) ;
$ anvil - > Log - > variables ( { source = > $ THIS_FILE , line = > __LINE__ , level = > $ debug , list = > { variable_source_uuid = > $ variable_source_uuid } } ) ;
}
}
if ( ( not exists $ anvil - > data - > { duplicate_variables } { $ variable_section } { $ variable_name } { $ variable_source_table } { $ variable_source_uuid } ) &&
if ( ( not exists $ anvil - > data - > { duplicate_variables } { $ variable_section } { $ variable_name } { $ variable_source_table } { $ variable_source_uuid } ) &&
@ -19726,7 +19726,7 @@ ORDER BY
# Save it.
# Save it.
$ anvil - > data - > { duplicate_variables } { $ variable_section } { $ variable_name } { $ variable_source_table } { $ variable_source_uuid } { variable_value } = $ variable_value ;
$ anvil - > data - > { duplicate_variables } { $ variable_section } { $ variable_name } { $ variable_source_table } { $ variable_source_uuid } { variable_value } = $ variable_value ;
$ anvil - > data - > { duplicate_variables } { $ variable_section } { $ variable_name } { $ variable_source_table } { $ variable_source_uuid } { variable_uuid } = $ variable_uuid ;
$ anvil - > data - > { duplicate_variables } { $ variable_section } { $ variable_name } { $ variable_source_table } { $ variable_source_uuid } { variable_uuid } = $ variable_uuid ;
$ anvil - > Log - > variables ( { source = > $ THIS_FILE , line = > __LINE__ , level = > 1 , list = > {
$ anvil - > Log - > variables ( { source = > $ THIS_FILE , line = > __LINE__ , level = > $ debug , list = > {
"duplicate_variables::${variable_section}::${variable_name}::${variable_source_table}::${variable_source_uuid}::variable_value" = > $ anvil - > data - > { duplicate_variables } { $ variable_section } { $ variable_name } { $ variable_source_table } { $ variable_source_uuid } { variable_value } ,
"duplicate_variables::${variable_section}::${variable_name}::${variable_source_table}::${variable_source_uuid}::variable_value" = > $ anvil - > data - > { duplicate_variables } { $ variable_section } { $ variable_name } { $ variable_source_table } { $ variable_source_uuid } { variable_value } ,
"duplicate_variables::${variable_section}::${variable_name}::${variable_source_table}::${variable_source_uuid}::variable_uuid" = > $ anvil - > data - > { duplicate_variables } { $ variable_section } { $ variable_name } { $ variable_source_table } { $ variable_source_uuid } { variable_uuid } ,
"duplicate_variables::${variable_section}::${variable_name}::${variable_source_table}::${variable_source_uuid}::variable_uuid" = > $ anvil - > data - > { duplicate_variables } { $ variable_section } { $ variable_name } { $ variable_source_table } { $ variable_source_uuid } { variable_uuid } ,
} } ) ;
} } ) ;
@ -19734,7 +19734,7 @@ ORDER BY
else
else
{
{
# Duplicate! This is older, so delete it.
# Duplicate! This is older, so delete it.
$ anvil - > Log - > variables ( { source = > $ THIS_FILE , line = > __LINE__ , level = > 1 , list = > {
$ anvil - > Log - > variables ( { source = > $ THIS_FILE , line = > __LINE__ , level = > $ debug , list = > {
"duplicate_variables::${variable_section}::${variable_name}::${variable_source_table}::${variable_source_uuid}::variable_value" = > $ anvil - > data - > { duplicate_variables } { $ variable_section } { $ variable_name } { $ variable_source_table } { $ variable_source_uuid } { variable_value } ,
"duplicate_variables::${variable_section}::${variable_name}::${variable_source_table}::${variable_source_uuid}::variable_value" = > $ anvil - > data - > { duplicate_variables } { $ variable_section } { $ variable_name } { $ variable_source_table } { $ variable_source_uuid } { variable_value } ,
"duplicate_variables::${variable_section}::${variable_name}::${variable_source_table}::${variable_source_uuid}::variable_uuid" = > $ anvil - > data - > { duplicate_variables } { $ variable_section } { $ variable_name } { $ variable_source_table } { $ variable_source_uuid } { variable_uuid } ,
"duplicate_variables::${variable_section}::${variable_name}::${variable_source_table}::${variable_source_uuid}::variable_uuid" = > $ anvil - > data - > { duplicate_variables } { $ variable_section } { $ variable_name } { $ variable_source_table } { $ variable_source_uuid } { variable_uuid } ,
} } ) ;
} } ) ;
@ -19752,7 +19752,7 @@ ORDER BY
push @ { $ queries } , "DELETE FROM variables WHERE variable_uuid = " . $ anvil - > Database - > quote ( $ variable_uuid ) . ";" ;
push @ { $ queries } , "DELETE FROM variables WHERE variable_uuid = " . $ anvil - > Database - > quote ( $ variable_uuid ) . ";" ;
foreach my $ query ( @ { $ queries } )
foreach my $ query ( @ { $ queries } )
{
{
$ anvil - > Log - > variables ( { source = > $ THIS_FILE , line = > __LINE__ , level = > 1 , list = > { query = > $ query } } ) ;
$ anvil - > Log - > variables ( { source = > $ THIS_FILE , line = > __LINE__ , level = > 2 , list = > { query = > $ query } } ) ;
}
}
$ anvil - > Database - > write ( { query = > $ queries , source = > $ THIS_FILE , line = > __LINE__ } ) ;
$ anvil - > Database - > write ( { query = > $ queries , source = > $ THIS_FILE , line = > __LINE__ } ) ;
}
}