Pulling in changes from Adam and cleaning up spaces in SGPstateData