public function recursiveMove()
 {
     foreach ($this->info->params->files as $file) {
         $renamecmd = 'mv -f ' . Helper::mb_escapeshellarg($file) . ' ' . Helper::mb_escapeshellarg($this->info->params->to);
         try {
             $this->LogCmdExec($renamecmd);
             $this->writeLog('0: OK: ' . $file . ' ');
         } catch (Exception $err) {
             $this->writeLog('0: Failed: ' . $file);
         }
     }
 }
 public function mediainfo($paths)
 {
     $filename = $this->getWorkDir($paths->target);
     if (!Fs::get()->isFile($filename)) {
         throw new Exception("Error Processing Request", 6);
     }
     $commands = array();
     $flags = '';
     $st = mediainfoSettings::load();
     $task = new rTask(array('arg' => call_user_func('end', explode('/', $filename)), 'requester' => 'mediainfo', 'name' => 'mediainfo', 'no' => 0));
     if ($st && !empty($st->data["mediainfousetemplate"])) {
         $randName = $task->makeDirectory() . "/opts";
         file_put_contents($randName, $st->data["mediainfotemplate"]);
         $flags = "--Inform=file://" . escapeshellarg($randName);
     }
     $commands[] = getExternal("mediainfo") . " " . $flags . " " . Helper::mb_escapeshellarg($filename);
     $ret = $task->start($commands, rTask::FLG_WAIT);
     return $ret;
 }