Resolving possible type error caused by invalid input
Move re compilation to the module load