I don't think they are tied together the sensor just turns on the system if it is off and starts the motor to take the disk in. If you damaged the cable as in my picture then the sensor will not work. Also note that there is another part (mirror I think) under the plate with the roller assembly that reflects the sensor beam. When the beam is interrupted the drive will sense the disk.
The drive will work with or without the sensor if the system is already on. I would recommend trying to fix the eject problem first.
I have 4-5 extra drives that I robbed lasers out of if you need parts. Or you can find a new drive on eBay for cheap.