File tree Expand file tree Collapse file tree 1 file changed +16
-1
lines changed Expand file tree Collapse file tree 1 file changed +16
-1
lines changed Original file line number Diff line number Diff line change 3535
3636use  OC \Files \Cache \FailedCache ;
3737use  OC \Files \Cache \NullWatcher ;
38+ use  OC \Files \Cache \Watcher ;
3839use  OC \Files \Filesystem ;
3940use  OC \Files \Storage \FailedStorage ;
4041use  OC \Files \Storage \Wrapper \PermissionsMask ;
4142use  OC \User \NoUserException ;
43+ use  OCA \Files_External \Config \ExternalMountPoint ;
4244use  OCP \Constants ;
4345use  OCP \Files \Cache \ICacheEntry ;
4446use  OCP \Files \NotFoundException ;
@@ -400,7 +402,20 @@ public function getOwner($path) {
400402		return  $ this superShare ->getShareOwner ();
401403	}
402404
403- 	public  function  getWatcher ($ path'' , $ storagenull ) {
405+ 	public  function  getWatcher ($ path'' , $ storagenull ): Watcher 
406+ 		$ mountManagerOC ::$ servergetMountManager ();
407+ 
408+ 		// Get node informations 
409+ 		$ node$ this getShare ()->getNodeCacheEntry ();
410+ 		if  ($ node
411+ 			$ mount$ mountManagerfindByNumericId ($ nodegetStorageId ());
412+ 			// If the share is originating from an external storage 
413+ 			if  (count ($ mount0  && $ mount0 ] instanceof  ExternalMountPoint) {
414+ 				// Propagate original storage scan 
415+ 				return  parent ::getWatcher ($ path$ storage
416+ 			}
417+ 		}
418+ 
404419		// cache updating is handled by the share source 
405420		return  new  NullWatcher ();
406421	}
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments