Skip to content

Conversation

@VirgileZol
Copy link
Contributor

@VirgileZol VirgileZol commented May 31, 2022

Q A
Bug fix? yes
New feature? no
BC breaks? no
Deprecations? no
Related tickets
Documentation
License MIT

What's in this PR?

Fix
Invalid type for path "httplug.clients.xxx.plugins.xxx.cache.config.cache_lifetime". Expected "int", but got "null".

cache_lifetime must be an integer or null

Example Usage

cache_lifetime: ~

Checklist

  • Updated CHANGELOG.md to describe bugfix

@VirgileZol VirgileZol marked this pull request as ready for review May 31, 2022 15:46
Copy link
Collaborator

@dbu dbu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks for the contribution, indeed null is an accepted value in the plugin.

i realize that the respect_response_cache_directives null is somehow inconsistent with the other options - for those where the plugin accepts null as option, we forward the null, which is different from the default value. according to https://github.com/php-http/cache-plugin/blob/master/src/CachePlugin.php#L233 we treat null as 0 for the cache_lifetime option.

@dbu dbu merged commit ced25d5 into php-http:master Jun 1, 2022
@dbu
Copy link
Collaborator

dbu commented Jun 1, 2022

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants