mirror of
https://github.com/nextcloud/docker.git
synced 2025-05-03 07:30:53 +02:00
Drop file_exists check for _FILE variables (#2234)
* Drop file_exists check for _FILE variables A PHP warning is generated if the file does not exist. Otherwise there is no indicator why the variable is not used. Signed-off-by: J0WI <J0WI@users.noreply.github.com> * fixup: typo in smtp.config.php Signed-off-by: Josh <josh.t.richards@gmail.com> --------- Signed-off-by: J0WI <J0WI@users.noreply.github.com> Signed-off-by: Josh <josh.t.richards@gmail.com> Co-authored-by: Josh <josh.t.richards@gmail.com>
This commit is contained in:
parent
064069b306
commit
2accbecd97
3 changed files with 6 additions and 6 deletions
|
@ -24,7 +24,7 @@ if (getenv('OBJECTSTORE_S3_BUCKET')) {
|
|||
)
|
||||
);
|
||||
|
||||
if (getenv('OBJECTSTORE_S3_KEY_FILE') && file_exists(getenv('OBJECTSTORE_S3_KEY_FILE'))) {
|
||||
if (getenv('OBJECTSTORE_S3_KEY_FILE')) {
|
||||
$CONFIG['objectstore']['arguments']['key'] = trim(file_get_contents(getenv('OBJECTSTORE_S3_KEY_FILE')));
|
||||
} elseif (getenv('OBJECTSTORE_S3_KEY')) {
|
||||
$CONFIG['objectstore']['arguments']['key'] = getenv('OBJECTSTORE_S3_KEY');
|
||||
|
@ -32,7 +32,7 @@ if (getenv('OBJECTSTORE_S3_BUCKET')) {
|
|||
$CONFIG['objectstore']['arguments']['key'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OBJECTSTORE_S3_SECRET_FILE') && file_exists(getenv('OBJECTSTORE_S3_SECRET_FILE'))) {
|
||||
if (getenv('OBJECTSTORE_S3_SECRET_FILE')) {
|
||||
$CONFIG['objectstore']['arguments']['secret'] = trim(file_get_contents(getenv('OBJECTSTORE_S3_SECRET_FILE')));
|
||||
} elseif (getenv('OBJECTSTORE_S3_SECRET')) {
|
||||
$CONFIG['objectstore']['arguments']['secret'] = getenv('OBJECTSTORE_S3_SECRET');
|
||||
|
@ -40,7 +40,7 @@ if (getenv('OBJECTSTORE_S3_BUCKET')) {
|
|||
$CONFIG['objectstore']['arguments']['secret'] = '';
|
||||
}
|
||||
|
||||
if (getenv('OBJECTSTORE_S3_SSE_C_KEY_FILE') && file_exists(getenv('OBJECTSTORE_S3_SSE_C_KEY_FILE'))) {
|
||||
if (getenv('OBJECTSTORE_S3_SSE_C_KEY_FILE')) {
|
||||
$CONFIG['objectstore']['arguments']['sse_c_key'] = trim(file_get_contents(getenv('OBJECTSTORE_S3_SSE_C_KEY_FILE')));
|
||||
} elseif (getenv('OBJECTSTORE_S3_SSE_C_KEY')) {
|
||||
$CONFIG['objectstore']['arguments']['sse_c_key'] = getenv('OBJECTSTORE_S3_SSE_C_KEY');
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue