-fixed errors that were going to occur in border check