GLENWOOD SPRINGS, Colo. (AP) — A Colorado bed and breakfast owner armed with just a length of rope helped save a black bear with a giant plastic container stuck on its head.

Jim Hawkins got his lasso around the animal’s midsection on the first throw. He said Thursday that he and the bear “did a rodeo thing for a while” before the animal figured out that Hawkins was the reason it couldn’t run away.

That’s when the bear went after Hawkins, leaving him with scrapes and a wound that needed stitches. It then scrambled up a tree, remaining there until officials arrived.

Carbondale District Wildlife Officer John Groves tells the Post Independent newspaper that officials tranquilized the bear and cut the container off its head.

It was released in the mountains and is expected to survive.