Fixing a bug that returned an Event ID rather than the application ID.