C4::Members::GetMember emitted a few unnecessary warnings when no $type was passed in. This patch prevents that.
No functional or documentation changes.
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
FROM borrowers
LEFT JOIN categories on borrowers.categorycode=categories.categorycode
";
- if ($type eq 'cardnumber' || $type eq 'firstname'|| $type eq 'userid'|| $type eq 'borrowernumber'){
+ if ( defined $type && ( $type eq 'cardnumber' || $type eq 'firstname'|| $type eq 'userid'|| $type eq 'borrowernumber' ) ){
$information = uc $information;
$sth = $dbh->prepare("$select WHERE $type=?");
} else {