feat: Expose ConversionUtil.

This commit is contained in:
Ruben Verborgh
2021-01-02 13:58:42 +01:00
parent a73936f522
commit dfc1d4662f
8 changed files with 46 additions and 43 deletions

View File

@@ -4,7 +4,7 @@ import type { ResourceIdentifier } from '../ldp/representation/ResourceIdentifie
import { getLoggerFor } from '../logging/LogUtil';
import { InternalServerError } from '../util/errors/InternalServerError';
import type { Conditions } from './Conditions';
import { matchingTypes } from './conversion/ConversionUtil';
import { matchingMediaTypes } from './conversion/ConversionUtil';
import type { RepresentationConverter, RepresentationConverterArgs } from './conversion/RepresentationConverter';
import { PassthroughStore } from './PassthroughStore';
import type { ResourceStore } from './ResourceStore';
@@ -77,7 +77,7 @@ export class RepresentationConvertingStore<T extends ResourceStore = ResourceSto
}
// Check if there is a result if we try to map the preferences to the content-type
return matchingTypes(preferences, [ contentType ]).length > 0;
return matchingMediaTypes(preferences, [ contentType ]).length > 0;
}
/**