diff --git a/lib/imagefile.php b/lib/imagefile.php index 97aa85c1ff..ba7e428f6d 100644 --- a/lib/imagefile.php +++ b/lib/imagefile.php @@ -63,7 +63,7 @@ class ImageFile if (!empty($this->id)) { $this->fileRecord = new File(); $this->fileRecord->id = $this->id; - if (!$this->find(true)) { + if (!$this->fileRecord->find(true)) { // If we have set an ID, we need that ID to exist! throw new NoResultException($this->fileRecord); }