Update to touch

This commit is contained in:
Henrik Kjölhede 2013-02-09 23:29:58 +01:00
parent 674955d1b6
commit 9e42a36fd8
1 changed files with 5 additions and 1 deletions

View File

@ -239,12 +239,16 @@ class SFTP extends OC\Files\Storage\Common {
public function touch($path, $mtime=null) {
try {
if ($mtime != null) return false;
if (!$this->file_exists($path)) {
$this->client->put($this->abs_path($path), '');
} else {
return false;
}
} catch (Exception $e) {
return false;
}
return true;
}
public function getFile($path, $target) {