use map instead for on creating hash tables

This commit is contained in:
Milan
2020-03-05 22:16:54 +01:00
parent da5f7f673d
commit 41b0495c2e
24 changed files with 40 additions and 144 deletions

View File

@@ -125,11 +125,7 @@ sub get_columns_hash($$) {
my $table = shift;
my $columns = db::get_columns( $dbh, $table );
my $result = {};
for my $column (@$columns) {
$result->{$column} = 1;
}
return $result;
return { map { $_ => 1 } @$columns };
}
#returns last inserted id