LAREDO, Texas – An undocumented immigrant has been sentenced after claiming he did not mean to assault a Border Patrol Agent.

39-year-old Mexican national Melecio Lopez-Hernandez was sentenced to a little more than 5 years in prison.

The defense attempted to convince the court that the immigrant thought the agent was a cow and was startled when the agent appeared.

The judge was not persuaded.

According to Local 23 sources, Hernandez was walking through the brush south of Freer when he was encountered by a Border Patrol Agent. Hernandez then began to struggle against the agent attempting to detain him, during which Hernandez dislodged a flashlight that was clipped to the agent’s outer vest.

Hernandez then verbally threatened the agent before striking him with the flashlight.