Changeset View
Changeset View
Standalone View
Standalone View
src/applications/people/query/PhabricatorPeopleQuery.php
Show First 20 Lines • Show All 404 Lines • ▼ Show 20 Lines | foreach ($events as $event) { | ||||
if (!isset($rebuild[$invitee_phid])) { | if (!isset($rebuild[$invitee_phid])) { | ||||
continue; | continue; | ||||
} | } | ||||
$map[$invitee_phid][] = $event; | $map[$invitee_phid][] = $event; | ||||
} | } | ||||
} | } | ||||
// We need to load these users' timezone settings to figure out their | |||||
// availability if they're attending all-day events. | |||||
$this->needUserSettings(true); | |||||
$this->fillUserCaches($rebuild); | |||||
foreach ($rebuild as $phid => $user) { | foreach ($rebuild as $phid => $user) { | ||||
$events = idx($map, $phid, array()); | $events = idx($map, $phid, array()); | ||||
// We loaded events with the omnipotent user, but want to shift them | // We loaded events with the omnipotent user, but want to shift them | ||||
// into the user's timezone before building the cache because they will | // into the user's timezone before building the cache because they will | ||||
// be unavailable during their own local day. | // be unavailable during their own local day. | ||||
foreach ($events as $event) { | foreach ($events as $event) { | ||||
$event->applyViewerTimezone($user); | $event->applyViewerTimezone($user); | ||||
▲ Show 20 Lines • Show All 156 Lines • Show Last 20 Lines |