The (-) input of the comparator is biased at a reference voltage with two resistors making a voltage divider. When light shines on the reverse-biased photodiode then it leaks a current that causes the (+) input's voltage to rise. When the voltage rises higher than the (-) input voltage then the output of the comparator will oscillate, or go high.OK in short we divide the voltage across the non inverting terminal right?
so that the photodiode itself will form a resistor and this photodiode will vary the resistance depending on received IR light.