Fix formatting (gofmt -w -s)
Fix SetSubStateSubscription bug
Merge pull request #2 from kraman/bugfix

Fix formatting and sub state subscription issues