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

"1d" gets converted to 24 days instead of 1 day #842

Closed
andriihorpenko opened this issue May 30, 2024 · 0 comments
Closed

"1d" gets converted to 24 days instead of 1 day #842

andriihorpenko opened this issue May 30, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@andriihorpenko
Copy link

Minecraft Version

1.19.2

KubeJS Version

1902.6.2-build.69

Rhino Version

1902.2.3-build.284

Architectury Version

6.6.92

Forge/Fabric Version

Forge 43.3.7

Describe your issue

For some reason, 86400 seconds (which is 1 day) is multiplied by 24, making it 24 days instead of 1. Same goes with weeks ('1w' is also calculated incorrectly).

https://github.com/KubeJS-Mods/KubeJS/blob/7219f93290ef147ca89ea41468cb58084f6e2634/src/main/java/dev/latvian/mods/kubejs/util/UtilsJS.java#L932C6-L932C66
image

Crash report/logs

No response

@andriihorpenko andriihorpenko added the bug Something isn't working label May 30, 2024
@andriihorpenko andriihorpenko changed the title '1d gets converted to 24 days instead of 1 day "1d" gets converted to 24 days instead of 1 day May 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants