Загрузите сразу два файла

Я пытаюсь загрузить сразу два файла (два поля файла) с классом загрузки codeigniters. Несмотря на то, что имя поля codeignign создает ошибки во втором поле.

Я это ограничение codeigniter, php или html или я просто использую класс неразумно?

$this->upload->do_upload('video_file') $this->upload->do_upload('image_file') 

Производит это в поле изображения:

 The filetype you are attempting to upload is not allowed. 

Вот мои две функции

 function upload_image() { $thumb_size = 94; $config['upload_path'] = './assets/uploads/images/'; $config['allowed_types'] = 'jpg|png|gif'; $config['max_size'] = '2048'; $config['file_name'] = 'video_' . rand(999999, 999999999); $this->load->library('upload', $config); if (!$this->upload->do_upload('image_file')) { $error = array('error' => $this->upload->display_errors()); return $error; } else { function upload_video() { $config['upload_path'] = './assets/uploads/videos/'; $config['allowed_types'] = 'flv'; $config['max_size'] = '0'; $config['file_name'] = 'video_' . rand(999999, 999999999); $this->load->library('upload', $config); if (!$this->upload->do_upload('video_file')) { $error = array('error' => $this->upload->display_errors()); return $error; } else { 

Он загружал класс как $this->load->library('upload'); затем используя $this->upload->initialize($config); каждый раз, когда я загружаю новый файл.