Skip to content

Commit 303b64c

Browse files
committed
Fix improperly named mailgun environment variable, closes pterodactyl#942
1 parent 8e1aa15 commit 303b64c

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

app/Console/Commands/Environment/EmailSettingsCommand.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ private function setupMailgunDriverVariables()
126126
trans('command/messages.environment.mail.ask_mailgun_domain'), $this->config->get('services.mailgun.domain')
127127
);
128128

129-
$this->variables['MAILGUN_KEY'] = $this->option('password') ?? $this->ask(
129+
$this->variables['MAILGUN_SECRET'] = $this->option('password') ?? $this->ask(
130130
trans('command/messages.environment.mail.ask_mailgun_secret'), $this->config->get('services.mailgun.secret')
131131
);
132132
}

tests/Unit/Commands/Environment/EmailSettingsCommandTest.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ public function testMailgunDriverSelection()
126126
$data = [
127127
'MAIL_DRIVER' => 'mailgun',
128128
'MAILGUN_DOMAIN' => 'domain.com',
129-
'MAILGUN_KEY' => '123456',
129+
'MAILGUN_SECRET' => '123456',
130130
'MAIL_FROM' => 'mail@from.com',
131131
'MAIL_FROM_NAME' => 'MailName',
132132
'MAIL_ENCRYPTION' => 'tls',
@@ -147,7 +147,7 @@ public function testMailgunDriverSelectionWithOptionsPassed()
147147
$data = [
148148
'MAIL_DRIVER' => 'mailgun',
149149
'MAILGUN_DOMAIN' => 'domain.com',
150-
'MAILGUN_KEY' => '123456',
150+
'MAILGUN_SECRET' => '123456',
151151
'MAIL_FROM' => 'mail@from.com',
152152
'MAIL_FROM_NAME' => 'MailName',
153153
'MAIL_ENCRYPTION' => 'tls',
@@ -160,7 +160,7 @@ public function testMailgunDriverSelectionWithOptionsPassed()
160160
'--from' => $data['MAIL_FROM_NAME'],
161161
'--encryption' => $data['MAIL_ENCRYPTION'],
162162
'--host' => $data['MAILGUN_DOMAIN'],
163-
'--password' => $data['MAILGUN_KEY'],
163+
'--password' => $data['MAILGUN_SECRET'],
164164
]);
165165

166166
$this->assertNotEmpty($display);

0 commit comments

Comments
 (0)