Moved border checking into the main method