title: Yii2 UploadedFile::saveAs() is not saving file
body: <p>Trying to upload file:</p>
  
  <pre><code>public function uploadFile(UploadedFile $file)
  {
      //  $this-&gt;image = $file;
      $file-&gt;saveAs(Yii::getAlias('@web').'uploads/'.$file-&gt;name);
      var_dump($file);
      die();
  }
  </code></pre>
  
  <p>But the file does not appear in the destination directory.</p>
  
  <p>Dump:</p>
  
  <blockquote>
    <p>object(yii\web\UploadedFile)#150 (5) { ["name"]=> string(12) "IMG_0005.jpg" ["tempName"]=> string(14) "/tmp/phpDFnzQp" ["type"]=> string(10) "image/jpeg" ["size"]=> int(877612) ["error"]=> int(0) }</p>
  </blockquote>