Initialize self.state to None

Without initializing self.state, python will enter an eternal loop if __getattr__ is called before init_app, which can very easily happen when using Flask blueprints.