joomlatools-platform
joomlatools-platform copied to clipboard
Debug is always on even though JOOMLA_DEBUG is false
Problem:
Even when the environment variable JOOMLA_DEBUG is set to "false", the debug is still still turned on.
Diagnosis:
Getting JOOMLA_CACHE and JOOMLA_DEBUG from the environment returns a string, so if the configuration is set based on the value like "false"
or "0"
, it will always be equivalent to true.
Solution:
Instead of setting the value as "false"
or "true"
, it should be set to "0"
or "1"
. Then the value should be converted into boolean through type casting.