Check the courtesy light switch either in the door frame or latch handle.
Spray some electrical contact cleaner in the switch.
If the vehicle has been in a prior collision the door may be out of line causing a switch fault
There is the chance a wire has corroded off or come loose from the switch.