Added checks for vector instead of just true before accessing some data stucts that are generated on the fly and can fail due to communication errors