Fixed state inheritance issue.