A cyclist riding on a trail near Jasper, Alberta was attacked by a grizzly and spared from any major injuries thanks to a can of pepper spray. The bear tried to bite Etienne Cardinal, a wildlife conflict specialist, but instead clamped down on a can of bear pepper spray and retreated.

Cardinal told CBC Canada his first reaction was to scream at the animal after it knocked him off his bike.

“I was 10 minutes from being back from town, and that’s when I had this little adventure,” he said. “I heard the bear first. He turned on me, just roaring at me … it was pretty quick, I didn’t really see it coming.”

But when the bear tried to bite Cardinal, it wrapped its jaws around his backpack instead and set off a bear spray canister strapped to the side.

“He had a mouthful of it, which is good,” Cardinal said. “I wasn’t realizing what was going on. I was screaming at it just so that it would stop. I fell on my knees waiting for more blows to come. But nothing came.”

Cardinal said the attack lasted about 10 seconds, and beside a few scratches on his back, he’s unharmed. While officials are still looking for the bear, they’re largely chalking the incident up to simply being in the wrong place at the wrong time.