cdnjs / api-server

📡 API server for api.cdnjs.com - The #1 free and open source CDN built to make life easier for developers.
https://api.cdnjs.com
MIT License
89 stars 38 forks source link

Return case-sensitive fields correctly #87

Closed MattIPv4 closed 1 year ago

MattIPv4 commented 1 year ago

Type of Change

What issue does this relate to?

Resolves #86

What should this PR do?

Ensures that we are correctly maintaining the casing of requested fields when they are case-sensitive, for the libraries endpoint (e.g. fields=fileType)

What are the acceptance criteria?

New tests correctly cover case-sensitive fields, and are passing. Requesting the fileType field on the libraries endpoint returns the field as expected, not null.