diff --git a/lib/Controller/WopiController.php b/lib/Controller/WopiController.php index 0910f14e..0ac399ea 100755 --- a/lib/Controller/WopiController.php +++ b/lib/Controller/WopiController.php @@ -549,7 +549,8 @@ public function putFile($fileId, $suggested = iconv('utf-7', 'utf-8', $suggested); if ($suggested[0] === '.') { - $path = dirname($file->getPath()) . '/New File' . $suggested; + $rawName = pathinfo($file->getName(), PATHINFO_FILENAME); + $path = dirname($file->getPath()) . '/' . $rawName . $suggested; } elseif ($suggested[0] !== '/') { $path = dirname($file->getPath()) . '/' . $suggested; } else {