Cleaned superfluous stuff out of main (debug remains)