File tree Expand file tree Collapse file tree 1 file changed +8
-8
lines changed Expand file tree Collapse file tree 1 file changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -91,22 +91,22 @@ protected function addServicesConfig(): void
91
91
*/
92
92
protected function addEnvs (string $ envFile ): void
93
93
{
94
- if ($ this ->chosenDriver === self ::DRIVER_OTHER ) {
94
+ // Do not add the entry if already exists
95
+ if (str_contains ($ envFile , 'MAILCARRIER_SOCIAL_AUTH_DRIVER= ' )) {
95
96
return ;
96
97
}
97
98
98
99
$ envPath = getcwd () . '/ ' . $ envFile ;
99
100
$ envFile = file_get_contents ($ envPath );
100
101
101
- // Do not add the entry if already exists
102
- if (str_contains ($ envFile , 'MAILCARRIER_SOCIAL_AUTH_DRIVER= ' )) {
103
- return ;
102
+ if ($ this ->chosenDriver === self ::DRIVER_OTHER ) {
103
+ $ envFile .= 'MAILCARRIER_SOCIAL_AUTH_DRIVER= ' . PHP_EOL ;
104
+ } else {
105
+ $ envFile .= 'MAILCARRIER_SOCIAL_AUTH_DRIVER= ' . strtolower ($ this ->chosenDriver ) .
106
+ PHP_EOL .
107
+ $ this ->buildEnvs ();
104
108
}
105
109
106
- $ envFile .= 'MAILCARRIER_SOCIAL_AUTH_DRIVER= ' . strtolower ($ this ->chosenDriver ) .
107
- PHP_EOL .
108
- $ this ->buildEnvs ();
109
-
110
110
file_put_contents ($ envPath , $ envFile );
111
111
}
112
112
You can’t perform that action at this time.
0 commit comments