From 7a43527175b8aa2bfea950a1b8a088ba34eeceb5 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Guillaume=20Perr=C3=A9al?= <guillaume.perreal@irstea.fr>
Date: Mon, 2 Mar 2015 15:30:21 +0100
Subject: [PATCH] =?UTF-8?q?UploadedFile:=20correction=20du=20changement=20?=
 =?UTF-8?q?de=20chemin=20quand=20on=20passe=20de=20l'=C3=A9tat=20orphelin?=
 =?UTF-8?q?=20=C3=A0=20normal.?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

---
 Entity/UploadedFile.php | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Entity/UploadedFile.php b/Entity/UploadedFile.php
index e8b935ea..2d1df85e 100644
--- a/Entity/UploadedFile.php
+++ b/Entity/UploadedFile.php
@@ -289,7 +289,7 @@ class UploadedFile implements UploadedFileInterface
 
         // Déplace le fichier hors de l'orphelinat quand on passe d'orphelin à nouveau
         if($this->etat === self::ETAT_ORPHELIN && $etat === self::ETAT_NORMAL && 0 === strpos($this->path, self::ORPHAN_PREFIX)) {
-            $this->path = substr($this->path, strlen($this->path));
+            $this->path = substr($this->path, strlen(self::ORPHAN_PREFIX));
         }
 
         $this->etat = $etat;
-- 
GitLab