pulsar-edit / package-backend

Pulsar Server Backend for Packages
https://api.pulsar-edit.dev
MIT License
11 stars 11 forks source link

Refactor Package Constructs #233

Closed confused-Techie closed 5 months ago

confused-Techie commented 5 months ago

Requirements

Description of the Change

This PR focuses on the important topic of Package Constructs. These Package Constructs are the functions that are in total control of what the data that's returned to users looks like. Which includes:

This PR moves them out of the utils file into the dedicated models directory, as what now should be done. Additionally I've gone ahead and added new tests for these constructions, as they are never tested directly (until now), while I've also found and resolved a bug of tarball_url being incorrectly included in Package Object JSON objects.