Added Nil checker when retrieving terms["teachingSemester"] from the REST server