소스 검색

feat: EK-1345: 发送email失败

kevinElken 8 달 전
부모
커밋
ec31b690c8
1개의 변경된 파일0개의 추가작업 그리고 15개의 파일을 삭제
  1. 0 15
      common/helpers/Email.php

+ 0 - 15
common/helpers/Email.php

@@ -2,14 +2,10 @@
 
 namespace common\helpers;
 
-require 'vendor/autoload.php';
-use Mailgun\Mailgun;
 use Yii;
 
 class Email
 {
-    private static $mailKey = '4f64981556009f8e9fc2e112a65d3be3-67bd41c2-4e17cb05';
-
     /**
      * @param string $email
      * @param string $userName
@@ -31,15 +27,4 @@ class Email
 
         LoggerTool::debug('sendRegistrationEmail' . sprintf('sendRegistrationEmail: %s', json_encode([$email, $userName, $password, $response])));
     }
-
-    public static function sendEmail(string $email, string $userName, string $password)
-    {
-        $mg = Mailgun::create(self::$mailKey);
-        $mg->messages()->send('ng-frontend-api.elken.com', [
-            'from' => 'Elken <no.reply.elken@gmail.com>',
-            'to' => $email,
-            'subject' => \Yii::t('app', 'decRegistrationEmailSubject', []),
-            'html' => \Yii::t('app', 'decRegistrationEmailContent', ['userName' => $userName, 'passWord' => $password]),
-        ]);
-    }
 }