Cleaned up and commented code.
Export application.