If it's 2 wires, they get connected to the motor. Just match the colors. If 3, the yellow goes to the light, white to motor and light, and dark color (blue or black?) to motor. The only reason Hoover wired it like this is to have the light on, even when the nozzle's motor was switched off.
www.vacuumcleanerhelp.com
November 2009