If CreateOrEditFolder etc. are async, then you have to await them. Not putting await doesn't mean you run them synchronously. It means you don't wait for it to finish executing before starting another, which causes the "Existing task is running on the same context" error.
Can you show the implementation of one of those methods?
Can you show the code for both "synchronously" and "asynchronously"?
Try:
- .OrderBy(input.Sorting ?? "myEntity.id asc")
+ .OrderBy(input.Sorting ?? "Id asc")
Use Git from the start.
I could not reproduce that when creating an user. Were you perhaps creating a tenant or self-registration?
PR: https://github.com/aspnetzero/aspnet-zero-core/pull/1561
just write summary/description on implement class, not interface
— https://github.com/aspnetboilerplate/aspnetboilerplate/issues/3285
You need to save changes in that method:
[UseCase(Description = "Updating User Contact Information")]
public async Task CreateOrEdit(CreateOrEditContactDto input)
{
if (input.Id == null)
{
await Create(input);
}
else
{
await Update(input);
}
// CurrentUnitOfWork.SaveChanges();
_unitOfWorkManager.Current.SaveChanges();
}
Fixed in v5.6
That looks like a service, not an entity.
Which class does it inherit and what's the error?