partial clean up with errors and footer additions