mirror of
https://gitlab.com/davical-project/davical.git
synced 2026-09-19 05:59:02 +00:00
Simplify logic slightly.
This commit is contained in:
parent
66bf7a39ef
commit
70b760fbea
@ -481,16 +481,16 @@ function collection_to_xml( $collection ) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if ( isset($prop_list['urn:ietf:params:xml:ns:caldav:calendar-free-busy-set'] ) ) {
|
if ( isset($prop_list['urn:ietf:params:xml:ns:caldav:calendar-free-busy-set'] ) ) {
|
||||||
if ( $collection->type == 'in' && $session->user_no == $collection->user_no ) {
|
if ( $session->user_no != $collection->user_no ) {
|
||||||
|
$reply->CalDAVElement( $denied, "calendar-free-busy-set");
|
||||||
|
}
|
||||||
|
else if ( $collection->type == 'in' ) {
|
||||||
$fb_set = array();
|
$fb_set = array();
|
||||||
foreach( $request->principal->calendar_free_busy_set AS $k => $v ) {
|
foreach( $request->principal->calendar_free_busy_set AS $k => $v ) {
|
||||||
$fb_set[] = $reply->href( $v, false, "DAV:" );
|
$fb_set[] = $reply->href( $v, false, "DAV:" );
|
||||||
}
|
}
|
||||||
$reply->CalDAVElement( $prop, "calendar-free-busy-set", $fb_set );
|
$reply->CalDAVElement( $prop, "calendar-free-busy-set", $fb_set );
|
||||||
}
|
}
|
||||||
else if ( $session->user_no != $collection->user_no ) {
|
|
||||||
$reply->CalDAVElement( $denied, "calendar-free-busy-set");
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user