The right way to do this is to modify the count pages plugin to allow setting callbacks when the job is completed. So the function that launches a job in that plugin should be modified to take another function as a parameter, that will be called when the job is completed.
|