Fixed reinitialization bug