1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-09-05 17:53:12 +02:00

fix: admin global features endpoint

The Admin global features endpoint was using the client features store
to join in environments, strategies and segments, when all we actually
need is the feature metadata. This PR swaps which method we use for
getting the data.

Co-authored-by: Fredrik Strand Oseberg <fredrik.no@gmail.com>
Co-authored-by: Simon Hornby <liquidwicked64@gmail.com>
This commit is contained in:
Christopher Kolstad 2022-07-14 13:50:41 +02:00
parent 7da461cc9f
commit ba21adf3ae
No known key found for this signature in database
GPG Key ID: 559ACB0E3DB5538A

View File

@ -177,9 +177,7 @@ class FeatureController extends Controller {
req: Request,
res: Response<FeaturesSchema>,
): Promise<void> {
const query = await this.prepQuery(req.query);
const features = await this.service.getFeatureToggles(query);
const features = await this.service.getMetadataForAllFeatures(false);
this.openApiService.respondWithValidation(
200,
res,