Why does dryer lint grill have wiring coming in?
It's almost certainly a moisture sensor.  Search YouTube for dryer moisture sensor bar, and you should get a bunch of results showing how to replace them.