resolveStaticFilesCacheMaxContentLength static method
int
resolveStaticFilesCacheMaxContentLength(
- int? max, {
- APIConfig? apiConfig,
})
Implementation
static int resolveStaticFilesCacheMaxContentLength(int? max,
{APIConfig? apiConfig}) {
if (max != null) return max;
if (apiConfig != null) {
max ??= apiConfig.getAs('static-files-cache-max-content-length');
max ??= apiConfig.getAs('static_files_cache_max_content_length');
max ??= apiConfig.getPath('cache', 'static_files', 'max_content_length');
}
max ??= APIServerResponseCache.defaultMaxContentLength;
return max;
}