refactor: refine worker factory arguments checking