OpenPerpetuum / PerpetuumServer

The Open Perpetuum Project's fork of the Perpetuum Standalone Server
https://openperpetuum.com
Other
44 stars 21 forks source link

Bootstrapper multiple calls to register item? #194

Open MikeJeffers opened 4 years ago

MikeJeffers commented 4 years ago

https://github.com/OpenPerpetuum/PerpetuumServer/blob/Development/src/Perpetuum.Bootstrapper/PerpetuumBootstrapper.cs#L918 https://github.com/OpenPerpetuum/PerpetuumServer/blob/Development/src/Perpetuum.Bootstrapper/PerpetuumBootstrapper.cs#L959-L960 https://github.com/OpenPerpetuum/PerpetuumServer/blob/Development/src/Perpetuum.Bootstrapper/PerpetuumBootstrapper.cs#L997-L998 Why? Multiple calls, no functional difference. Is this tech-debt or some obscurity of Autofac I don't understand?

LoyalServant commented 4 years ago

I think they are safe to remove. Autofac likely ignores the second and subsequent calls to register the same type.