same here for error checking.