Updated for dispatch API change