Correct a bug when add_job try to manage duplicate jobs