TORONTO -- A 24-year-old man was saved from a whirlpool on Saturday by an off-duty officer and several others after the hiker crossed a creek and was swept away by the current.

The man had been hiking on a trail in Bass Lake, Calif.,when he walked across Willow Creek near Angel Falls. The Madera County Sheriff’s Office said in a Facebook post that the man misjudged the “swiftness of the water” and was swept into the whirlpool.

In the video posted by the police department, off-duty officer Brent Donley can be seen using a rope and large branch to pull the man to safety with the help of other hikers in the area.

“A 24-year-old Fresno man needs to buy a lottery ticket because today is his lucky day,” the post read.

Donley is a California Highway Patrol officer who had been hiking in the area with his wife when he came across the man in danger. He’s also trained in search and rescue.

According to the sheriff’s post, the Willow Creek is known for fierce-flowing waters that can travel as fast as 50-80 feet (15-24 metres) per second.

Donley stayed with the hiker and provided first aid until emergency services arrived, but no injuries were reported.

“We sincerely thank Officer Donley for his quick-thinking and preparedness. This search and rescue call could have ended very badly if not for his help,” the post read.

Along with the video of the rescue, the sheriff’s office urged viewers to not cross swift water or jump in to save drowning victims when visiting the mountains.