Base solution for your next web application
Starts in:
01 DAYS
01 HRS
01 MIN
01 SEC
Open Closed

NullReference when starting application for the first time if MultiTenancy is disabled #6873


User avatar
0
limingjun2018 created

1 Answer(s)
  • User Avatar
    0
    maliming created
    Support Team

    When disabling multi-tenancy you can set the tenantId to MultiTenancyConsts.DefaultTenantId;

    https://github.com/aspnetzero/aspnet-zero-core/blob/dev/aspnet-core/src/MyCompanyName.AbpZeroTemplate.EntityFrameworkCore/Migrations/Seed/Host/DefaultSettingsCreator.cs#L26

    see https://github.com/aspnetzero/aspnet-zero-core/issues/2272#issuecomment-484338209