diff --git a/lib/IdPAccountManager/WebRequest.pm b/lib/IdPAccountManager/WebRequest.pm index 10c2dff54093dc97b35bcacca42a261c3a13b7d6..04e02a9cba88dfef8de3ab141a85ce30f3879bd2 100755 --- a/lib/IdPAccountManager/WebRequest.pm +++ b/lib/IdPAccountManager/WebRequest.pm @@ -175,37 +175,6 @@ sub respond { $self->{logger}->errorf("Web parser error : %s", $tt2->error()); } - ## Ignore some type of errors - my @errors_admin; - foreach my $id_error (@{ $self->{out}->{errors} }) { - unless ($id_error =~ /^(error_x)$/) { - push @errors_admin, $id_error; - } - } - - ## Mail notification of admins about the error - if (@errors_admin) { - eval { - IdPAccountManager::Tools::mail_notice( - template => 'mail/notification_generic_error.tt2.eml', - templates_dir => $self->{configuration}->{templates_dir}, - data => { - env => { - REMOTE_HOST => $ENV{REMOTE_HOST}, - REMOTE_ADDR => $ENV{REMOTE_ADDR}, - }, - conf => { - app_name => $self->{configuration}->{app_name}, - app_url => $self->{configuration}->{app_url}, - }, - from => $self->{configuration}->{notice_from}, - to => $self->{configuration}->{admin_email}, - errors => $self->{out}->{errors} - } - ); - }; - $self->{logger}->errorf("Error TT2 : %s", $EVAL_ERROR) if $EVAL_ERROR; - } } ## Return the list of known SPs first diff --git a/templates/Makefile.am b/templates/Makefile.am index b1571840e3a48aa27b81bd9cf634f5c3f5f5b5a6..f24227ff98d0c4f36a9fbf5a8954f4ebb34ef5ae 100644 --- a/templates/Makefile.am +++ b/templates/Makefile.am @@ -11,7 +11,6 @@ nobase_templates_DATA = \ accountProfiles/teacher1.tt2 \ accountProfiles/teacher2.tt2 \ accountProfiles/valid-accounts.php.tt2 \ - mail/notification_generic_error.tt2.eml \ mail/send_authentication_token.tt2.eml \ web/account_wizard.tt2.html \ web/content.tt2.html \ diff --git a/templates/mail/notification_generic_error.tt2.eml b/templates/mail/notification_generic_error.tt2.eml deleted file mode 100644 index 2430cc407e6be13f254472258ba5b893d7571eff..0000000000000000000000000000000000000000 --- a/templates/mail/notification_generic_error.tt2.eml +++ /dev/null @@ -1,20 +0,0 @@ -From: [% app_name %] <[% from %]> -To: [% to %] -Subject: [% app_name %] - Error notification -Content-type: text/plain; charset=UTF-8; format=flowed - -You receive this notification as administrator of the eduGAIN Test Account Manager -An error occured during test account processing. - -[% IF error_type == 'skipping_provider_metadata_issue' %] -Le fichier de méta-données pour le provider [% entityid %] a un format incorrect ou n'a pas pu être téléchargé. - -L'URL des méta-données : [% provider.get('metadataurl') %] - -Check logs for more details -[% ELSE %] -Error: [% errors.join(',') %] -@IP : [% env.REMOTE_HOST %] / [% env.REMOTE_ADDR %] - -Check logs for more details -[% END %]