Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Symfony\Component\RateLimiter\Policy\SlidingWindow::getExpirationTime(): Return value must be of type int, float returned #45924

Copy link
Copy link
Closed
@georgringer

Description

@georgringer
Issue body actions

Symfony version(s) affected

5.4.7

Description

With the commit of symfony/rate-limiter@4716500 the method getExpirationTime changed and now a float is returned but the return type is set to int which produces an exception

How to reproduce

No out of box code available but using microtime(true) returns a float

Possible Solution

type cast like

return (int)($this->windowEndAt + $this->intervalInSeconds - microtime(true));

Additional Context

No response

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

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.