$terms = $jobterms->get();
foreach ($terms as $term) {
if ($this->pid == $term->pid && array_key_exists($term->jid, $this->jobs)) {
$terms = $jobterms->get();
foreach ($terms as $term) {
if ($this->pid == $term->pid && array_key_exists($term->jid, $this->jobs)) {