public static void ExistingLifetimeScope(this ContainerCustomizations customizations, ILifetimeScope lifetimeScope) { customizations.Settings.Set<AutofacBuilder.LifetimeScopeHolder>(new AutofacBuilder.LifetimeScopeHolder(lifetimeScope)); } }