What steps will reproduce the problem?
1. Obtain an ical file with multiple properties and parameters -- e.g. the
attached Test.ics has one event with multiple attendees, and the attendees have
multiple parameters (CN, CUTYPE, PARTSTAT, etc)
2. Write a test harness to parse the ical file
3. output JSON for the parsed event.
What is the expected output? What do you see instead?
Expect the JSON to contain multiple different attendees with all parameters
from the ical file.
the correct number of attendees are shown, but they are all identical and equal
to the first attendee. Only the last parameter parsed for the attendee is shown
(RSVP: True)
What version of the product are you using? On what operating system?
ijp R4 from svn interpreted by either Safari 5.0.2 or Firefox 3.6.12 on MacOSX
10.5.8 parsing an iCal file created with Apple iCal 3.0.8
Please provide any additional information below.
I think the first error relates to you passing the full event text back into
getValue circa line 189 after you have found multiple entries, instead of the
individual matches. Each call to getValue is just finding the same first match.
If you pass each match in turn, it will find the individual matches as
expected. In order for this to work, however, you have change the code to not
terminate the regexp at the first colon (:) in the original match circa line
182, or the value for the match is not passed.
The second error is down to the clustering in your regular expression near line
194 -- the interpreter returns the last parameter match instead of all the
matches.
Both these are fixed in the version I am currently running at
http://www.burlington.manchester.ac.uk/javascripts/ijp/ijp.js
and I attach my patch.
Original issue reported on code.google.com by burli...@googlemail.com on 12 Dec 2010 at 2:46
Original issue reported on code.google.com by
burli...@googlemail.com
on 12 Dec 2010 at 2:46Attachments: