Issues with time converting

I see why it’s because “seconds” was out of scope when you attempted to return it, I’ve fixed that by adding “local seconds = 1” so that when the return statement is executed “seconds” is in scope.

Now it works, but if I do “1d” is only bans says 1 second.

image

Must be some other issue on your end.

And that was using my function and it worked? Strange…

I copied the exact thing from what you put and still will not work just shows 1

I’m assuming the data you’re passing to the function is incorrect, look at the way in which I called the function.

1 Like