 
   @startNextJob: ->
     job = @jobs[0]
-    job.task?.start job.args, @dispatchMisspellings
+    job.manager.check(job.args, job.args.text).then (results) =>
+      @removeFromArray(@jobs, (j) -> j.args.id is job.args.id)
+      callback(results.misspellings) for callback in job.callbacks
 
-  @dispatchMisspellings: (data) =>
-    job = @removeFromArray(@jobs, (j) -> j.args.id is data.id)
-    for callback in job.callbacks
-      callback(data.misspellings)
-
-    @startNextJob() if @jobs.length > 0
+      @startNextJob() if @jobs.length > 0

  @handler: null
  @jobs: []

  constructor: (@task) ->
    @id = idCounter++

  terminate: ->

    @constructor.startNextJob() if @constructor.jobs.length is 1

  @piggybackExistingJob: (newJob) ->
    if @jobs.length > 0
      for job in @jobs
        if @isDuplicateRequest(job, newJob)
          job.callbacks = job.callbacks.concat(newJob.callbacks)
          return true
    return false
