working on getting state working again