Hello, I am using .net core + angular aspnetzero template. After I upload my own logo, the logo can't be retrieved back. This is the error in the audit logs
Abp.AbpException: Session.TenantId is null! Possible problems: No user logged in or current logged in user in a host user (TenantId is always null for host users).
at Abp.Runtime.Session.AbpSessionExtensions.GetTenantId(IAbpSession session)
at CoGen.Arkgene.Web.Controllers.TenantCustomizationController.<GetLogo>d__5.MoveNext() in C:\Users\Justin\Source\Repos\ArkGene\aspnet-core\src\CoGen.Arkgene.Web.Core\Controllers\TenantCustomizationController.cs:line 120
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiter1.GetResult() at Microsoft.AspNetCore.Mvc.Internal.ObjectMethodExecutor.<CastToObject>d__38
1.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()
at Microsoft.AspNetCore.Mvc.Internal.ControllerActionInvoker.
Getting logo when logged in or logged out doesn't work as well.
1 Answer(s)
-
0
Hi,
In which page are you getting this error? When you check the source code the image is being requested only session has tenant and logo id. But if you are requesting image directly, and you are not logged on then you can see that error.
<a class="postlink" href="https://github.com/aspnetzero/aspnet-zero-core/blob/master/angular/src/app/shared/layout/header.component.html#L5">https://github.com/aspnetzero/aspnet-ze ... nt.html#L5</a>