This is truly the stuff of nightmares for anyone who has a fear of enclosed spaces. A repairman was found locked in a wall behind an ATM after he sent notes out of the dispenser asking for help.

The Washington Post reports the man was sent to replace a lock on the door to the small service room behind the ATM but forgot to bring his phone and the tool to open the door from the inside. When the door closed on him, he was stuck.

Police in Corpus Christi, Texas were notified and thought it might be a prank. However, when they inspected the ATM they heard a small voice talking back to them.

The man was freed from his hours-long ordeal by police and sent on his way. Surely it’s a lesson only needing to be learned once.