From ecdf44ddd982c894bbe2ff35afdcffc0d6d11083 Mon Sep 17 00:00:00 2001 From: Andrew McMillan Date: Sat, 6 Mar 2010 00:19:09 +1300 Subject: [PATCH] Use NeedPrivilege to respond to access denied. --- inc/caldav-OPTIONS.php | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/inc/caldav-OPTIONS.php b/inc/caldav-OPTIONS.php index 00556f58..714d8d83 100644 --- a/inc/caldav-OPTIONS.php +++ b/inc/caldav-OPTIONS.php @@ -10,9 +10,7 @@ */ dbg_error_log("OPTIONS", "method handler"); -if ( ! $request->AllowedTo('read') ) { - $request->DoResponse( 403, translate("You may not access that collection") ); -} +$request->NeedPrivilege( 'DAV::read' ); $exists = false; $is_calendar = false;