Visual Studio C# compiler warns about accidentally assigning a variable to itself, but this warning does not apply to C# properties, only variables. As described in this other q
Change the way you type the parameters, so the error happens less often.
Parameter first:
public Foo(ILogger logger)
{
}
Assignment next: copy/paste the parameter twice
public Foo(ILogger logger)
{
// this.{paste} = {paste};
this.logger = logger;
}
Lastly, correct the misspelt property:
public Foo(ILogger logger)
{
this.Logger = logger;
}