Seems to be a bug when creating a UDF: Now() becomes a date in year 2001


Basically, I am getting the wrong results from a UDF I’ve created.

The UDF in javascript contains this part:


and the request output for that part is:


However, when I inspect it in Fauna dashboard, I see:

GTE(Time("2001-01-21T10:10:58.665120Z"), Var("from"))

Why? :frowning:

I changed the function to use Now() in the dashboard, and suddenly the UDF works as expected.

Btw, JS driver is 3.0.1. I’ll try to upgrade and see the results.

It worked when I used faunadb.js 4.0.0. :slight_smile: