PLANE_ICAO is only inited once after startup from "sim/aircraft/view/acf_ICAO" in ReadAllScriptFiles .
Some planes e.g. the ToLiss A321 may change this from A321 to A21N during its plugin initialization.
That leads to some random behavior of PLANE_ICAO's value due to different timing.
A cure could be to refresh this value some time after a "livery loaded" message is received by the FWL plugin.