HOUSTON (CNN) – A Houston man was in the right place at the right time after his neighbor’s dog leash got caught in an elevator door.

The incident was all recorded on a security camera at their apartment building on Monday

In the 39-second clip, Johnny Mathis posted on Twitter, you see a woman walking into the elevator with her dog on the leash. But the door closes before the dog gets in!

Mathis who has just got off the elevator jumps in and to get dog off the leash just in time. but quickly coming back to pick up the Pomeranian once he saw the owner was gone and it was still stuck there alone.

Mathis says the woman was overjoyed when she found out that her puppy wasn’t hurt.