(function(){return function(e,t,r){var a=Scanner.fromMessage(e);a.setLocale(t);var n,o,i,s,p,g,l,h,m,d,u={},v=[],c=[];n=a.getSpan().next(r.reservationId).nextAnyTag("td").tagContents();for(var C=a.getSpan().next(r.flightDetails).parentAnyTag("table"),A=C.allInnerTags("tr2"),l=1;l<A.length;l++){d=A[l];var T=d.allInnerTags("td2"),f=T[5].tagContents();u[f]={name:f},(""+T[0].tagContents()).length>0&&v.push(T)}for(var y=[],l=0;l<v.length;l++){var d=v[l],x=d[0].innerDate(),s=d[1].tagContents(),S=combineDateAndTime(x,s),p=d[2].tagContents(),b=combineDateAndTime(x,p);Date.parse(S)>Date.parse(b)&&(b=modifyDate(b,1));for(var o=d[3].tagContents().innerCapture(/([A-Z]{2,3})\s?(\d+)/),D=o[2],N=o[1],F=d[4].tagContents().innerCapture(regExpFormatted(/([A-Z]{3})\s\1\s([A-Z]{3})/,r.to)),i=F[1],g=F[2],k=Object.keys(u),f=F[0],I=[],R=0;R<k.length;R++){f=f.next(k[R]);I.push({passengerName:f,seat:f.nextAnyTag("td").tagContents()})}ASSERT(S,b,i,g)&&y.push({departureTime:S,arrivalTime:b,departureAirportCode:i,arrivalAirportCode:g,flightNumber:D,airlineCode:N,passengers:I})}for(l=0;l<y.length;l++){d=y[l],h=d.passengers;for(var R=0;R<h.length;R++){m=h[R];c.push({"@context":"http://schema.org","@type":"http://schema.org/FlightReservation",reservationFor:{"@type":"http://apple.com/FuzzyFlight",airlineName:"Aero M\xe9xico",airlineCode:d.airlineCode,flightNumber:d.flightNumber,departureAirportCode:d.departureAirportCode,departureTime:d.departureTime,arrivalAirportCode:d.arrivalAirportCode,arrivalTime:d.arrivalTime},underName:{"@type":"http://schema.org/Person",name:m.passengerName},reservationId:n,reservationStatus:"http://schema.org/ReservationConfirmed",reservedTicket:{"@type":"http://schema.org/Ticket",ticketedSeat:{"@type":"http://schema.org/Seat",seat:m.seat}}})}}if(c.length)return c}}).call();