aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/RedDAV/RedFile.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/include/RedDAV/RedFile.php b/include/RedDAV/RedFile.php
index 9ce6490a7..b7aa5473a 100644
--- a/include/RedDAV/RedFile.php
+++ b/include/RedDAV/RedFile.php
@@ -80,7 +80,8 @@ class RedFile extends DAV\Node implements DAV\IFile {
$newName = str_replace('/', '%2F', $newName);
$r = q("UPDATE attach SET filename = '%s' WHERE hash = '%s' AND id = %d",
- dbesc($this->data['filename']),
+ dbesc($newName),
+ dbesc($this->data['hash']),
intval($this->data['id'])
);
}