Debugcode in Mainstate removed