6.0.0-beta1
▾
Tasks
New Task
Search
Photos
Wiki
▾
Tickets
New Ticket
Search
dev.horde.org
Toggle Alerts Log
Help
8/1/25
H
istory
A
ttachments
C
omment
W
atch
Download
Comment on [#6606] Problem with attend.php and getByUID()
*
Your Email Address
*
Spam protection
Enter the letters below:
__..__..___..___.. . (__ | | | | |\/| .__)|__| | | | |
Comment
> The problem appears when a user tries to accept an event using the link > > provided. attend.php, the script which updates the status, uses (line 46): > > > > $event = $kronolith_driver->getByUID($uid); > > > > getByUID returns the first copy of an event (remember that no session > > has been started), but maybe, on BD exists other copies of the event, > > some of them without attendees. In that case, kronolith returns a "You > > are not an attendee of the specified event." message. > > > > I have solved the problem like this: > > > > - $event = $kronolith_driver->getByUID($uid); > > + $events = $kronolith_driver->getByUID($uid,true); > > + foreach ($events as $e){ > > + if ($e->hasAttendee($user)){ > > + $event=$e; > > + } > > + } > > > > In that solution, i allways suppose that only one event has the > correct attendee info (copies souldn't), so i examine every copy > returned by getByUID. > > > > I did not make a path for that because i don't know if my solution is > the best one. > >
Attachment
Watch this ticket
N
ew Ticket
M
y Tickets
S
earch
Q
uery Builder
R
eports
Saved Queries
Open Bugs
Bugs waiting for Feedback
Open Bugs in Releases
Open Enhancements
Enhancements waiting for Feedback
Bugs with Patches
Enhancements with Patches
Release Showstoppers
Stalled Tickets
New Tickets
Horde 5 Showstoppers