summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorBart Visscher <bartv@thisnet.nl>2012-07-25 23:07:10 +0200
committerBart Visscher <bartv@thisnet.nl>2012-07-25 23:09:03 +0200
commit381e493a8c777a4e5e95fd72c6a7ed8114c3c978 (patch)
treee6500675d75f9665e9cf24559b9998a9c0cf9b12 /lib
parentf25ccaff59c135d7f1f22196bf266916ef131b35 (diff)
downloadnextcloud-server-381e493a8c777a4e5e95fd72c6a7ed8114c3c978.tar.gz
nextcloud-server-381e493a8c777a4e5e95fd72c6a7ed8114c3c978.zip
Rename functions
getETagPropertyForFile -> getETagPropertyForPath removeETagPropertyForFile -> removeETagPropertyForPath
Diffstat (limited to 'lib')
-rw-r--r--lib/connector/sabre/directory.php2
-rw-r--r--lib/connector/sabre/file.php4
-rw-r--r--lib/connector/sabre/node.php4
-rw-r--r--lib/filesystem.php2
4 files changed, 6 insertions, 6 deletions
diff --git a/lib/connector/sabre/directory.php b/lib/connector/sabre/directory.php
index 0842fc4fc65..7003a920277 100644
--- a/lib/connector/sabre/directory.php
+++ b/lib/connector/sabre/directory.php
@@ -52,7 +52,7 @@ class OC_Connector_Sabre_Directory extends OC_Connector_Sabre_Node implements Sa
$newPath = $this->path . '/' . $name;
OC_Filesystem::file_put_contents($newPath,$data);
- return OC_Connector_Sabre_Node::getETagPropertyForFile($newPath);
+ return OC_Connector_Sabre_Node::getETagPropertyForPath($newPath);
}
/**
diff --git a/lib/connector/sabre/file.php b/lib/connector/sabre/file.php
index 80f0a0ab4d8..4fd50591071 100644
--- a/lib/connector/sabre/file.php
+++ b/lib/connector/sabre/file.php
@@ -47,7 +47,7 @@ class OC_Connector_Sabre_File extends OC_Connector_Sabre_Node implements Sabre_D
OC_Filesystem::file_put_contents($this->path,$data);
- return OC_Connector_Sabre_Node::getETagPropertyForFile($this->path);
+ return OC_Connector_Sabre_Node::getETagPropertyForPath($this->path);
}
/**
@@ -98,7 +98,7 @@ class OC_Connector_Sabre_File extends OC_Connector_Sabre_Node implements Sabre_D
if (isset($properties[self::GETETAG_PROPERTYNAME])) {
return $properties[self::GETETAG_PROPERTYNAME];
}
- return $this->getETagPropertyForFile($this->path);
+ return $this->getETagPropertyForPath($this->path);
}
/**
diff --git a/lib/connector/sabre/node.php b/lib/connector/sabre/node.php
index 663970487fb..77aff92cc39 100644
--- a/lib/connector/sabre/node.php
+++ b/lib/connector/sabre/node.php
@@ -208,7 +208,7 @@ abstract class OC_Connector_Sabre_Node implements Sabre_DAV_INode, Sabre_DAV_IPr
* @param string $path Path of the file
* @return string|null Returns null if the ETag can not effectively be determined
*/
- static public function getETagPropertyForFile($path) {
+ static public function getETagPropertyForPath($path) {
$tag = OC_Filesystem::hash('md5', $path);
if (empty($tag)) {
return null;
@@ -223,7 +223,7 @@ abstract class OC_Connector_Sabre_Node implements Sabre_DAV_INode, Sabre_DAV_IPr
* Remove the ETag from the cache.
* @param string $path Path of the file
*/
- static public function removeETagPropertyForFile($path) {
+ static public function removeETagPropertyForPath($path) {
$query = OC_DB::prepare( 'DELETE FROM *PREFIX*properties WHERE userid = ? AND propertypath = ? AND propertyname = ?' );
$query->execute( array( OC_User::getUser(), $path, self::GETETAG_PROPERTYNAME ));
}
diff --git a/lib/filesystem.php b/lib/filesystem.php
index 81370d4e178..c87bc9ed9cb 100644
--- a/lib/filesystem.php
+++ b/lib/filesystem.php
@@ -475,7 +475,7 @@ class OC_Filesystem{
static public function removeETagHook($params) {
$path=$params['path'];
- OC_Connector_Sabre_Node::removeETagPropertyForFile($path);
+ OC_Connector_Sabre_Node::removeETagPropertyForPath($path);
}
}
OC_Hook::connect('OC_Filesystem','post_write', 'OC_Filesystem','removeETagHook');