VERO BEACH, Fla. (WFLA) — A German Shepherd that was stranded on a Florida island for four days was rescued Tuesday, the Vero Beach Police Department said.

Police said they received several calls reporting a loose dog around Memorial Island. The dog was seen running into the water and swimming to the island directly southwest of Memorial Island.

Officers and animal control tried to rescue the dog for several days but had trouble locating it. The dog was said to run away as soon as it heard anyone nearby. Officials said they left dog food and water for the dog and eventually set up a trap.

Around 11 a.m. Tuesday, a boater decided to check in on the dog and noticed the German Shepherd had been secured in the trap.

The German Shepherd was taken to the Humane Society for observation, police said.

“If unable to locate the owner of the German Shepherd, we will be looking for a foster family for this handsome dog,” the police department posted on Facebook.