protected virtual Task<Application> GetApplicationAsync(string identifier, CancellationToken cancellationToken) {
// Retrieve the application details corresponding to the requested client_id.
return (from application in database.Applications
where application.ApplicationID == identifier
select application).SingleOrDefaultAsync(cancellationToken);
}
}