Fix for haxe >=3.1 & openfl