We should call the DBI quote function for integer.
This commit is contained in:
parent
e2a63b30fa
commit
eee5a0d3d6
1 changed files with 2 additions and 1 deletions
|
@ -481,7 +481,8 @@ sub _verifyId($$) {
|
||||||
|
|
||||||
die "_verifyId() called with a non-numeric id" unless defined $id and looks_like_number($id);
|
die "_verifyId() called with a non-numeric id" unless defined $id and looks_like_number($id);
|
||||||
|
|
||||||
my $val = $self->dbh()->selectall_hashref("SELECT id FROM supporter WHERE id = $id", 'id');
|
my $val = $self->dbh()->selectall_hashref("SELECT id FROM supporter WHERE id = " .
|
||||||
|
$self->dbh->quote($id, 'SQL_INTEGER'), 'id');
|
||||||
return (defined $val and defined $val->{$id});
|
return (defined $val and defined $val->{$id});
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue