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

Changed all C# control flow block statements to include space between keyword and open paren

This commit is contained in:
Chad Scharf
2020-03-27 14:36:37 -04:00
parent 943aea9a12
commit 9800b752c0
243 changed files with 2258 additions and 2258 deletions

View File

@ -40,7 +40,7 @@ namespace Bit.Api
// Settings
var globalSettings = services.AddGlobalSettingsServices(Configuration);
if(!globalSettings.SelfHosted)
if (!globalSettings.SelfHosted)
{
services.Configure<IpRateLimitOptions>(Configuration.GetSection("IpRateLimitOptions"));
services.Configure<IpRateLimitPolicies>(Configuration.GetSection("IpRateLimitPolicies"));
@ -64,7 +64,7 @@ namespace Bit.Api
// BitPay
services.AddSingleton<BitPayClient>();
if(!globalSettings.SelfHosted)
if (!globalSettings.SelfHosted)
{
// Rate limiting
services.AddSingleton<IIpPolicyStore, MemoryCacheIpPolicyStore>();
@ -118,7 +118,7 @@ namespace Bit.Api
config.Conventions.Add(new PublicApiControllersModelConvention());
}).AddNewtonsoftJson(options =>
{
if(Environment.IsProduction() && Configuration["swaggerGen"] != "true")
if (Environment.IsProduction() && Configuration["swaggerGen"] != "true")
{
options.SerializerSettings.ContractResolver = new DefaultContractResolver();
}
@ -126,13 +126,13 @@ namespace Bit.Api
services.AddSwagger(globalSettings);
if(globalSettings.SelfHosted)
if (globalSettings.SelfHosted)
{
// Jobs service
Jobs.JobsHostedService.AddJobsServices(services);
services.AddHostedService<Jobs.JobsHostedService>();
}
if(CoreHelpers.SettingHasValue(globalSettings.ServiceBus.ConnectionString) &&
if (CoreHelpers.SettingHasValue(globalSettings.ServiceBus.ConnectionString) &&
CoreHelpers.SettingHasValue(globalSettings.ServiceBus.ApplicationCacheTopicName))
{
services.AddHostedService<Core.HostedServices.ApplicationCacheHostedService>();
@ -152,7 +152,7 @@ namespace Bit.Api
// Default Middleware
app.UseDefaultMiddleware(env, globalSettings);
if(!globalSettings.SelfHosted)
if (!globalSettings.SelfHosted)
{
// Rate limiting
app.UseMiddleware<CustomIpRateLimitMiddleware>();
@ -183,7 +183,7 @@ namespace Bit.Api
app.UseEndpoints(endpoints => endpoints.MapDefaultControllerRoute());
// Add Swagger
if(Environment.IsDevelopment() || globalSettings.SelfHosted)
if (Environment.IsDevelopment() || globalSettings.SelfHosted)
{
app.UseSwagger(config =>
{