make sure path starts with /
This commit is contained in:
parent
7892204077
commit
fdc7a8b204
|
@ -65,6 +65,9 @@ if($source) {
|
|||
$target=$dir.'/'.$filename;
|
||||
$result=OC_Filesystem::file_put_contents($target, $sourceStream);
|
||||
if($result) {
|
||||
if($target[0] != '/') {
|
||||
$target = '/'.$target;
|
||||
}
|
||||
$meta = OC_FileCache::get($target);
|
||||
$mime=$meta['mimetype'];
|
||||
$id = OC_FileCache::getId($target);
|
||||
|
|
Loading…
Reference in New Issue