aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Storage/File.php
diff options
context:
space:
mode:
authorzotlabs <mike@macgirvin.com>2017-03-22 19:31:43 -0700
committerzotlabs <mike@macgirvin.com>2017-03-22 19:31:43 -0700
commit0499deea6969129bd3b642f2d4edd676e1e5d4c9 (patch)
treeeb0ccd0af6fe0029b2256a0fe935124b44ae0d1f /Zotlabs/Storage/File.php
parent0fb024190192c92e542bceb486e8875ddabfdeb6 (diff)
downloadvolse-hubzilla-0499deea6969129bd3b642f2d4edd676e1e5d4c9.tar.gz
volse-hubzilla-0499deea6969129bd3b642f2d4edd676e1e5d4c9.tar.bz2
volse-hubzilla-0499deea6969129bd3b642f2d4edd676e1e5d4c9.zip
more cloud updates - upgrade the DAV structures as well.
Diffstat (limited to 'Zotlabs/Storage/File.php')
-rw-r--r--Zotlabs/Storage/File.php12
1 files changed, 11 insertions, 1 deletions
diff --git a/Zotlabs/Storage/File.php b/Zotlabs/Storage/File.php
index d2bca3964..1475241ab 100644
--- a/Zotlabs/Storage/File.php
+++ b/Zotlabs/Storage/File.php
@@ -85,13 +85,23 @@ class File extends DAV\Node implements DAV\IFile {
intval($this->data['id'])
);
+ $x = attach_syspaths($this->auth->owner_id,$this->data['hash']);
+
+ $y = q("update attach set display_path = '%s where hash = '%s' and uid = %d",
+ dbesc($x['path']),
+ dbesc($this->data['hash']),
+ intval($this->auth->owner_id)
+ );
+
if($this->data->is_photo) {
- $r = q("update photo set filename = '%s' where resource_id = '%s' and uid = %d",
+ $r = q("update photo set filename = '%s', display_path = '%s' where resource_id = '%s' and uid = %d",
dbesc($newName),
+ dbesc($x['path']),
dbesc($this->data['hash']),
intval($this->auth->owner_id)
);
}
+
$ch = channelx_by_n($this->auth->owner_id);
if($ch) {
$sync = attach_export_data($ch,$this->data['hash']);