Infrared Beam Relay

Ok, i fogot to mention i am new to electronics. :open_mouth:
Where would i need a pulldown/pullup resistor? I dont think i have one - i certainly haven't installed one. What is its purpose?