code: public function moveUploadedFile()
      {
          $this->dateCreated = new DateTime();
  
          if (null === $this->_uploadedFile) {
              return;
          }
  
          $this->_uploadedFile->move(dirname($this->path), basename($this->path));
          $this->_uploadedFile = null;
      }
docs: Move Uploaded File
  
  If the file was uploaded, then this method will move the uploaded file from the temporary
  directory to its new path.
  
  This is usually automatically handled as this method is a prePersist lifecycle callback.
  
  @ORM\PrePersist