'/cgi-bin/koha/opac-shelves.pl?display=privateshelves&viewshelf=';
use CGI qw ( -utf8 );
-use Email::Valid;
+use Email::Address;
use C4::Auth qw( get_template_and_user );
use C4::Context;
foreach my $a (@temp) {
$a =~ s/^\s+//;
$a =~ s/\s+$//;
- if ( IsEmailAddress($a) ) {
+ if ( $a =~ m/$Email::Address::mailbox/ ) {
push @appr_addr, $a;
}
else {
);
}
-sub IsEmailAddress {
-
- #TODO candidate for a module?
- return Email::Valid->address( $_[0] ) ? 1 : 0;
-}
-
sub randomlist {
#uses rand, safe enough for this application but not for more sensitive data