use map for table columns

This commit is contained in:
Milan
2020-03-08 00:24:15 +01:00
parent ea9590f6dc
commit 7b565c6d9b
20 changed files with 38 additions and 59 deletions

View File

@@ -15,9 +15,8 @@ sub debug;
sub get_columns($) {
my $config = shift;
my $dbh = db::connect($config);
my $cols = db::get_columns( $dbh, 'calcms_studios' );
return { map { $_ => undef } @$cols };
my $dbh = db::connect($config);
return db::get_columns_hash( $dbh, 'calcms_studios' );
}
sub get($;$) {
my $config = shift;