From 3e5ac7cdcc85ec6ea5f6f72889cf95815d29470f Mon Sep 17 00:00:00 2001 From: Igor Date: Wed, 26 Feb 2014 14:09:09 +1300 Subject: [PATCH] Update File.php Adding warning, took me a couple hours to figure this out... The file does not get moved because of this line: https://github.com/silverstripe/silverstripe-framework/blob/3.1/filesystem/File.php#L515 Maybe add to the method doc, telling people to set ParentId and Name instead if they want to change the location of a file (if that's the correct method). --- filesystem/File.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/filesystem/File.php b/filesystem/File.php index d88f00af1..358c190be 100644 --- a/filesystem/File.php +++ b/filesystem/File.php @@ -732,7 +732,7 @@ class File extends DataObject { } /** - * Does not change the filesystem itself, please use {@link write()} for this. + * Caution: this does not change the location of the file on the filesystem. */ public function setFilename($val) { $this->setField('Filename', $val);