adlnet / xAPIWrapper

Wrapper to simplify communication to an LRS
https://adlnet.gov/projects/xapi/
Apache License 2.0
219 stars 114 forks source link

Is not getLRSObject a spec violation? #143

Closed cawerkenthin closed 5 years ago

cawerkenthin commented 5 years ago

I am not sure when the change was made, but the extended vars added by getLRSObject do not work in a conformant LRS. I do not understand the logic of grabbing every parameter from the querystring and adding them back to all LRS calls. Our LRS correctly rejects calls to the get the State document, for example, because additional parameters used on the content launch line are not allowed in calls to State API.

vbhayden commented 5 years ago

Will look at this today, good catch.

vbhayden commented 5 years ago

Looks like this one from August:

https://github.com/adlnet/xAPIWrapper/commit/cee119319995d573f59c8d1174311c30af99341e#diff-1b2039be21a4454c52d6b497832996eb

cawerkenthin commented 5 years ago

I believe this is the current offending code in getLRSObject():

if (Object.keys(qsVars).length !== 0) { lrs.extended = qsVars; }