Skip to content

Commit

Permalink
Cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
generik0 committed Dec 10, 2020
1 parent 6d4d75e commit b9753fb
Showing 1 changed file with 3 additions and 14 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,25 +21,14 @@ namespace Castle.Windsor.Extensions.DependencyInjection.Scope
internal class ServiceScope : IServiceScope
{
private readonly IDisposable scope;
private readonly IServiceProvider serviceProvider;

public ServiceScope(IDisposable windsorScope, IServiceProvider serviceProvider)
{
if(windsorScope == null)
{
throw new ArgumentNullException(nameof(scope));
}

if(serviceProvider == null)
{
throw new ArgumentNullException(nameof(serviceProvider));
}

this.scope = windsorScope;
this.serviceProvider = serviceProvider;
scope = windsorScope ?? throw new ArgumentNullException(nameof(scope));
ServiceProvider = serviceProvider ?? throw new ArgumentNullException(nameof(serviceProvider));
}

public IServiceProvider ServiceProvider => serviceProvider;
public IServiceProvider ServiceProvider { get; }

public void Dispose()
{
Expand Down

0 comments on commit b9753fb

Please sign in to comment.