Have a look at MDLSITE-5967 and coding style: Sometimes the MOODLE_INTERNAL check is simply not necessary, so you get the hint to drop the line.
General developer forum
Unexpected MOODLE_INTERNAL check ???
This discussion has been locked so you can no longer reply to it.