Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix initialization of autocreate and use_ssl #2309

Merged
merged 1 commit into from
Oct 24, 2024

Commits on Oct 9, 2024

  1. Fix initialization of autocreate and use_ssl

    According to the documentation, both `OBJECTSTORE_S3_SSL` and
    `OBJECTSTORE_S3_AUTOCREATE` should default to `true`.
    Currently, when these environment variables are not set, they default to
    `false`. (See nextcloud#2308).
    
    This fix works, because `strtolower(false)` returns the empty string. So
    when `OBJECTSTORE_S3_SSL` is not set and `getenv('OBJECTSTORE_S3_SSL')`
    returns `false`, the check `strtolower($use_ssl) !== 'false'` will
    evaluate to `true`.
    
    With this fix, both values will be `true` if they are
    
    * not set
    * the empty string
    * any string that is not equal to `false` when converted to lowercase
    
    This should now match the documented behavior.
    
    Signed-off-by: Valentin Brandl <mail@vbrandl.net>
    vbrandl committed Oct 9, 2024
    Configuration menu
    Copy the full SHA
    053da1e View commit details
    Browse the repository at this point in the history