Removed all old code from main script