Made it so that in extendMatch if the ungapped extension fails then gapped extension is not carried out.