Startup crashes if the provided startup is null.

This PR fixes the startup logic by using the correct variable and therefore fixes a `NullReferenceException` if null was provided.