Add unload function to base application.