Anyway, testing different scenarios, I had some very weird results: where I was expecting the test to always evalute to false, I had a case where the condition resolved to true:
under mfprintv2.2.0 bundled into GeoNetwork and using Jetty as a servlet container the case evaluated to false in my debugger, true when stepping over
Doing the same with a tomcat9.x docker container and the condition evaluated to false.
There is probably some string interning black magick taking place over here, but at least we should reach the expected behaviour using equals instead of the "==" operator.
The test should probably be a
.equals()
hereAnyway, testing different scenarios, I had some very weird results: where I was expecting the test to always evalute to false, I had a case where the condition resolved to true:
There is probably some string interning black magick taking place over here, but at least we should reach the expected behaviour using equals instead of the "==" operator.