diff --git a/src/PhpImap/IncomingMailAttachment.php b/src/PhpImap/IncomingMailAttachment.php index 7b6d399d..2678c562 100644 --- a/src/PhpImap/IncomingMailAttachment.php +++ b/src/PhpImap/IncomingMailAttachment.php @@ -115,7 +115,7 @@ public function saveToDisk() : bool return false; } - if (false === file_put_contents($this->filePath, $this->dataInfo->fetch())) { + if (false === file_put_contents($this->__get('filePath'), $this->dataInfo->fetch())) { unset($this->filePath, $this->file_path); return false;