/** * Adds a modification to the models modifications array. * * @param BatchModification $modification * * @return $this */ public function addModification(BatchModification $modification) { $batch = $modification->get(); if (is_array($batch)) { $this->modifications[] = $batch; } return $this; }