1
0
mirror of https://github.com/bitwarden/server.git synced 2025-07-01 08:02:49 -05:00

Clean up remove-server-version-header feature flag (#5573)

* Removed feature flag.

* Linting.
This commit is contained in:
Todd Martin
2025-03-30 12:57:05 -04:00
committed by GitHub
parent 6e81cee221
commit c154b6ad9b
2 changed files with 0 additions and 11 deletions

View File

@ -1,5 +1,4 @@
using System.Collections;
using Bit.Core;
using Bit.Core.Services;
using Bit.Core.Settings;
using Bit.Core.Utilities;
@ -25,15 +24,6 @@ public sealed class RequestLoggingMiddleware
public Task Invoke(HttpContext context, IFeatureService featureService)
{
if (!featureService.IsEnabled(FeatureFlagKeys.RemoveServerVersionHeader))
{
context.Response.OnStarting(() =>
{
context.Response.Headers.Append("Server-Version", AssemblyHelpers.GetVersion());
return Task.CompletedTask;
});
}
using (_logger.BeginScope(
new RequestLogScope(context.GetIpAddress(_globalSettings),
GetHeaderValue(context, "user-agent"),