Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Breaking Change: Change SaveState in Csla.Blazor.State.StateManager from void to Task #3797

Closed
StefanOssendorf opened this issue Apr 14, 2024 · 1 comment · Fixed by #3906

Comments

@StefanOssendorf
Copy link
Contributor

public void SaveState()
{
var isBrowser = OperatingSystem.IsBrowser();
if (isBrowser)
{
_sessionManager.SendSession();
}
}
}

As shown above the _sessionManager.SendSession() method returns a Task which is currently ignored due to the voidness of the method. I think this should be changed for 9.0 to Task to make it possible to await that.

@rockfordlhotka
Copy link
Member

Agreed. I should have fixed it before releasing CSLA 8.

It was originally void because it was designed to be called in a page's Dispose method, and this was the implementation that worked in that context.

Now that state manager no longer works that way, this should be async.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Development

Successfully merging a pull request may close this issue.

3 participants