Add invariant to check getInitialState return value. Fixes #397
Merge pull request #725 from cpojer/getInitialState-invariant

Add invariant to check getInitialState return value. Fixes #397.