mirror of
https://gitlab.com/wgp/dougal/software.git
synced 2025-12-06 12:37:08 +00:00
NOTE: This is a breaking API change. Before this it returned an array of labels, now it returns an object.
15 lines
274 B
JavaScript
15 lines
274 B
JavaScript
|
|
const { project } = require('../../../lib/db');
|
|
|
|
module.exports = async function (req, res, next) {
|
|
|
|
try {
|
|
const labels = (await project.configuration.get(req.params.project))?.labels ?? {};
|
|
res.status(200).send(labels);
|
|
next();
|
|
} catch (err) {
|
|
next(err);
|
|
}
|
|
|
|
};
|