added some state guards