Skip to content

Commit bda42b6

Browse files
committed
Unset redis password if empty.
1 parent 69cd330 commit bda42b6

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

app/Console/Commands/Environment/AppSettingsCommand.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,11 +147,15 @@ private function checkForRedis()
147147
$this->output->comment(trans('command/messages.environment.app.redis_pass_help'));
148148
$this->variables['REDIS_PASSWORD'] = $this->option('redis-pass') ?? $this->output->askHidden(
149149
trans('command/messages.environment.app.redis_password'), function () {
150-
return true;
150+
return '';
151151
}
152152
);
153153
}
154154

155+
if (empty($this->variables['REDIS_PASSWORD'])) {
156+
unset($this->variables['REDIS_PASSWORD']);
157+
}
158+
155159
$this->variables['REDIS_PORT'] = $this->option('redis-port') ?? $this->ask(
156160
trans('command/messages.environment.app.redis_port'), $this->config->get('database.redis.default.port')
157161
);

0 commit comments

Comments
 (0)