Re-add global application instance

This was unintentially removed in c808613.