Skip to content

Conversation

@kenjis
Copy link
Member

@kenjis kenjis commented Oct 23, 2023

Description
In the docs, the param $expire is "Number of seconds until expiration", and the type is int:
https://www.codeigniter.com/user_guide/helpers/cookie_helper.html#set_cookie

So it should be int, not string.

The param $expires_or_options for setcookie() is also int.
https://www.php.net/manual/en/function.setcookie.php

Checklist:

  • Securely signed commits
  • Component(s) with PHPDoc blocks, only if necessary or adds value
  • Unit testing, with >80% coverage
  • User guide updated
  • Conforms to style guide

@kenjis kenjis added bug Verified issues on the current code behavior or pull requests that will fix them breaking change Pull requests that may break existing functionalities 4.5 labels Oct 23, 2023
@kenjis kenjis force-pushed the fix-set_cookie-expire branch from f9dd43a to 67f2b78 Compare October 23, 2023 04:36
@kenjis kenjis merged commit 9f1e38d into codeigniter4:4.5 Oct 27, 2023
@kenjis kenjis deleted the fix-set_cookie-expire branch October 27, 2023 21:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

breaking change Pull requests that may break existing functionalities bug Verified issues on the current code behavior or pull requests that will fix them

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants