It is shown that a vortex trapped in one of the banks of a planar edge-type Josephson junction in a narrow thin-film superconducting strip can change drastically the field dependence of the junction critical current $I_c(H)$. When the vortex is trapped at certain positions in the strip middle, the pattern $I_c(H)$ has zero at $H=0$ instead of the traditional maximum of 0-type junctions. The number of these positions is equal to the number of vortices trapped at the same location. When the junction-vortex separation exceeds approximately $2W$, $I_c(H)$ is no longer sensitive to the vortex presence.