diff options
author | Phie <phie@phie.ovh> | 2019-08-18 00:27:17 +0300 |
---|---|---|
committer | Phie <phie@phie.ovh> | 2019-08-18 00:27:17 +0300 |
commit | 9981f90c000a91463bde33cee4273cda80507ccc (patch) | |
tree | 583a65b2fbfbd3ef2530a8c2b99e860661d883d5 /lib | |
parent | 0a2dcc433b62f38bfd48e52199120493544ea689 (diff) |
fix note creation
Diffstat (limited to 'lib')
-rwxr-xr-x | lib/Controller/NoteController.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/Controller/NoteController.php b/lib/Controller/NoteController.php index f67de0e..83b8cf0 100755 --- a/lib/Controller/NoteController.php +++ b/lib/Controller/NoteController.php @@ -841,7 +841,6 @@ $path = $_GET['path']; $cache = $this->getCacheFolder(); - $folder = $cache->newFolder("currentnote".$editUniqueID); try{ $tmppath = tempnam(sys_get_temp_dir(), uniqid().".zip"); file_put_contents($tmppath,$this->CarnetFolder->get($path)->fopen("r")); @@ -852,10 +851,11 @@ } catch(\PhpZip\Exception\ZipNotFoundEntry $e){} $data['html'] = $zipFile['index.html']; unlink($tmppath); - shell_exec('php occ carnet:opennote '.escapeshellarg($this->userId).' '.escapeshellarg($path).' '.escapeshellarg($editUniqueID).'> /dev/null 2>/dev/null &'); } catch(\OCP\Files\NotFoundException $e) { $data["error"] = "not found"; } + shell_exec('php occ carnet:opennote '.escapeshellarg($this->userId).' '.escapeshellarg($path).' '.escapeshellarg($editUniqueID).'> /dev/null 2>/dev/null &'); + $data['id'] = $editUniqueID; return $data; |