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

Bug: results on getX() not equal #4452

Closed
totoprayogo1916 opened this issue Mar 19, 2021 · 1 comment · Fixed by #4453
Closed

Bug: results on getX() not equal #4452

totoprayogo1916 opened this issue Mar 19, 2021 · 1 comment · Fixed by #4453
Labels
bug Verified issues on the current code behavior or pull requests that will fix them

Comments

@totoprayogo1916
Copy link
Contributor

At the doc: https://codeigniter4.github.io/userguide/libraries/time.html#viewing-differences
image

Describe the bug
The result is not equal,
one is positive value
and the other is negative value

echo $diff->getSeconds();
// return: -220924800

echo $diff->seconds;
// return: 220924800

CodeIgniter 4 version
v4.1.1

@totoprayogo1916 totoprayogo1916 added the bug Verified issues on the current code behavior or pull requests that will fix them label Mar 19, 2021
@totoprayogo1916 totoprayogo1916 changed the title Bug: wrong results on getX() not equal Bug: results on getX() not equal with either getX() methods Mar 19, 2021
@totoprayogo1916 totoprayogo1916 changed the title Bug: results on getX() not equal with either getX() methods Bug: results on getX() not equal Mar 19, 2021
kenjis added a commit to kenjis/CodeIgniter4 that referenced this issue Mar 19, 2021
@kenjis
Copy link
Member

kenjis commented Mar 19, 2021

I think the property value is a bug. The user guide is correct.
See #4453

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Verified issues on the current code behavior or pull requests that will fix them
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants