mirror of
https://github.com/nextcloud/server.git
synced 2026-03-27 04:43:20 -04:00
Merge branch 'master' into sharing
This commit is contained in:
commit
2c4fef91da
3 changed files with 15 additions and 13 deletions
|
|
@ -40,17 +40,19 @@ $query=strtolower($query);
|
|||
|
||||
$files=array();
|
||||
|
||||
if(OC_FILESYSTEM::is_dir($base)){
|
||||
if(OC_FILESYSTEM::file_exists($base) and OC_FILESYSTEM::is_dir($base)){
|
||||
$dh = OC_FILESYSTEM::opendir($base);
|
||||
if(substr($base,-1,1)!='/'){
|
||||
$base=$base.'/';
|
||||
}
|
||||
while (($file = readdir($dh)) !== false) {
|
||||
if ($file != "." && $file != ".."){
|
||||
if(substr(strtolower($file),0,$queryLen)==$query){
|
||||
$item=$base.$file;
|
||||
if((!$dirOnly or OC_FILESYSTEM::is_dir($item))){
|
||||
$files[]=(object)array('id'=>$item,'label'=>$item,'name'=>$item);
|
||||
if($dh){
|
||||
if(substr($base,-1,1)!='/'){
|
||||
$base=$base.'/';
|
||||
}
|
||||
while (($file = readdir($dh)) !== false) {
|
||||
if ($file != "." && $file != ".."){
|
||||
if(substr(strtolower($file),0,$queryLen)==$query){
|
||||
$item=$base.$file;
|
||||
if((!$dirOnly or OC_FILESYSTEM::is_dir($item))){
|
||||
$files[]=(object)array('id'=>$item,'label'=>$item,'name'=>$item);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
<div class='crumb' data-dir='/'>
|
||||
<a href="<?php echo link_to("files", "index.php?dir=/"); ?>"><img src="<?php echo image_path("", "actions/go-home.png"); ?>" alt="Root"/></a>
|
||||
<a href="<?php echo link_to("files", "index.php"); ?>"><img src="<?php echo image_path("", "actions/go-home.png"); ?>" alt="Root"/></a>
|
||||
</div>
|
||||
<?php foreach($_["breadcrumb"] as $crumb): ?>
|
||||
<div class='crumb' data-dir='<?php echo $crumb["dir"];?>'>
|
||||
|
|
|
|||
|
|
@ -416,9 +416,9 @@ class OC_FILESYSTEM{
|
|||
}
|
||||
OC_HOOK::emit( 'OC_FILESYSTEM', 'post_copy', array( 'oldpath' => $path1 ,'newpath'=>$path2));
|
||||
if(!$exists){
|
||||
OC_HOOK::emit( 'OC_FILESYSTEM', 'post_create', array( 'path' => $path));
|
||||
OC_HOOK::emit( 'OC_FILESYSTEM', 'post_create', array( 'path' => $path2));
|
||||
}
|
||||
OC_HOOK::emit( 'OC_FILESYSTEM', 'post_write', array( 'path' => $path));
|
||||
OC_HOOK::emit( 'OC_FILESYSTEM', 'post_write', array( 'path' => $path2));
|
||||
return $result;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue