File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2323
2424use OCA \DAV \Connector \Sabre \Exception \Forbidden ;
2525use OCA \DAV \Connector \Sabre \File as DavFile ;
26- use OCA \DAV \Meta \MetaFile ;
27- use OCP \Files \FileInfo ;
2826use OCP \Files \NotFoundException ;
2927use Psr \Log \LoggerInterface ;
3028use Sabre \DAV \Server ;
3634 * Sabre plugin for restricting file share receiver download:
3735 */
3836class ViewOnlyPlugin extends ServerPlugin {
39-
4037 private ?Server $ server = null ;
4138 private LoggerInterface $ logger ;
4239
@@ -99,9 +96,7 @@ public function checkViewOnly(RequestInterface $request): bool {
9996 throw new Forbidden ('Access to this resource has been denied because it is in view-only mode. ' );
10097 }
10198 } catch (NotFound $ e ) {
102- $ this ->logger ->warning ($ e ->getMessage (), [
103- 'exception ' => $ e ,
104- ]);
99+ // File not found
105100 }
106101
107102 return true ;
You can’t perform that action at this time.
0 commit comments