The PNP sensor:- This is a sensor whose output pulls up to the positive supply rail when it senses a metal target. Thus any attached load to the sensor output must be connected between zero volts & the output of the sensor to operate.
This type of sensor is very vulnerable to short circuits to earth ( zero volts), a common fault if the wiring chafes/ becomes damaged. Often it will fry under this type of fault.
NPN sensor :- This is a sensor whose output pulls down to the negative ( 0 volts) supply rail when it senses a metal target. Thus any attached load to the sensor output must be connected between the Positive supply rail & the output of the sensor to operate. This type of sensor cannot survive a short up to the positive supply rail ( a very rare occurrence!). Shorts to the negative rail (zero volts) will not damage it at all & it can tolerate this indefinately.