http://coldfusion.com logo
#lucee
Title
# lucee
s

Simone

03/10/2022, 10:23 PM
mm/dd/yyyy MessageDigest not available added a hash(now(),'mm/dd/yyyy') to this.Applicationname
b

bdw429s

03/10/2022, 10:24 PM
@Simone Start by looking at what the second param to the
hash()
function is
And then look at what you're passing in
And see what's wrong
s

Simone

03/10/2022, 10:24 PM
found it, missing dateformat
b

bdw429s

03/10/2022, 10:25 PM
It's worth noting, this will give you a fresh application scope every day
Is that really what you want?
It doesn't seem like a behavior I'd want in production
s

Simone

03/10/2022, 10:37 PM
right now yes,
later it can be changed
m

Matt Jones

03/10/2022, 10:48 PM
out of curiosity, why bother with the hash if you are doing that?
m

Michael Schmidt

03/10/2022, 11:15 PM
This personally feels really dirty i do something like this to give me application a name based on directory location
this.name =  ReREPlaceNoCase(getDirectoryFromPath(getCurrentTemplatePath()), "[/\\:]", "_", "ALL");
Why would you go through the expense of hashing it if it is just part of your name you could easily
this.name=DateFormat(Now(), 'CFAPP_mm_dd_yyyy'));
g

gsr

03/10/2022, 11:45 PM
Maybe he is doing it just for fun