Skip to content

[BUG] sharedMaxAge calculation problem a page with one of the s-max-age is null #18160

@jean-pasqualini

Description

@jean-pasqualini

Symfony 2.3.16
PHP 5.4.41-0+deb7u1 (cli) (built: May 28 2015 18:22:26)

https://github.com/symfony/symfony/blob/master/src/Symfony/Component/HttpKernel/HttpCache/ResponseCacheStrategy.php#L79.

In the case of a page /example-1

  • Page (s-max-age: 86400)
    • block A (s-max-age: null)
    • block B (s-max-age: 0)

The s-max-age injected by symfony in the response is not 0 but 86400.

Validation by test : php -r "var_dump(min(array(1,2,3,null, 0)));"

In the case of a page /example-2

  • Page (s-max-age: 86400)
    • block A (s-max-age: 0)
    • block B (s-max-age: null)

The s-max-age injected by symfony in the response is 0.

Validation by test : php -r "var_dump(min(array(1,2,3, 0, null)));"

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      pFad - Phonifier reborn

      Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

      Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


      Alternative Proxies:

      Alternative Proxy

      pFad Proxy

      pFad v3 Proxy

      pFad v4 Proxy