Function not working after updating lucee server

I’m facing an issue since I did an upgrade from lucee server 5.3.2 to 5.3.8

The problem comes here with the function lsdateformat(). This is how it is used :

dateIssue.lsDateFormat('short')

After changing it to

dateIssue.lsDateFormat(dateIssue, 'short')

it seems to work. The problem is that before this upgrade, everything worked fine and changing it in all the code is a huge work.

I tried to see between which versions the error pops up and it is from the version 5.3.3

The error triggered is

The function [lsDateFormat] does not exist in the String, but there is a similar function with name [listItemTrim] available.

After looking at the release notes, I could not notice what can be causing this

Thanks for your help

OS: Win 10 Pro
Java Version: 8
Tomcat Version: 8.5.35

@lo93 Could you please check dateIssue variable type is DateTime or String in 5.3.8?
If dateIssue is a valid DateTime string(“2021-11-24”) or any string value means it doesn’t work with DateTime member functions TryCF.com .

Thanks for your answer.

What I figured it out since the value comes from the database, in the version 5.3.2, the value returned is sometimes null which is correct since we compare with !isNull(). With the update, this value is not anymore NULL but an empty string. Is it something that changed from the version 2 to 3 ?

Okay I found the problem. Between the version 5.3.2 and 5.3.3, there’s modification according to the NULL support

[LDEV-2236] - Lucee

In Lucee Server, we need to enable the full support. When the database was returning NULL, it was converted as empty string

1 Like