Skip to content

Commit

Permalink
Limit number of queried rows to 1 in DB method select_one()
Browse files Browse the repository at this point in the history
  • Loading branch information
maxhq committed May 31, 2022
1 parent 3c3029b commit 8b2acc5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/server/OpenXPKI/Server/Database.pm
Expand Up @@ -360,7 +360,7 @@ sub select {
# Returns: DBI statement handle
sub select_one {
my $self = shift;
return $self->select(@_)->fetchrow_hashref;
return $self->select(@_, limit => 1)->fetchrow_hashref;
}

# SELECT - return all rows as list of arrays
Expand Down

0 comments on commit 8b2acc5

Please sign in to comment.