Skip to content

Courses endpoint returns incorrect format for difficulties #338

@brianhogg

Description

@brianhogg

Reproduction Steps

  1. Create a course with two or more difficulties
  2. Make an API call to /wp-json/llms/v1/courses

Expected Behavior

Difficulties is an array of integers as per the documentation

Actual Behavior

A string with a comma-separated list of integers is returned

Tech Notes

We may want to create a v2 of the endpoint with the fix so it won't break the code of anyone relying on the current incorrect format.

This issue has been recreated:

  • Locally
  • On a staging site
  • On a production website
  • With only LifterLMS and a default theme

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

Status

Awaiting Triage

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions