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

:BeforeSave() doesn't get called if the datastore hasn't been updated #167

Closed
3pin3phrin3 opened this issue Feb 12, 2023 · 0 comments
Closed

Comments

@3pin3phrin3
Copy link

3pin3phrin3 commented Feb 12, 2023

This is not a bug but I thought I'd leave this here.

It makes sense not to call :BeforeSave() when no data has been updated but in my use case I'm updating temporary session data before the player leaves regardless of whether other data has been updated or not.

To change this behavior go inside the SaveAsync promise and modify the resolving conditions to pass when both not self.valueUpdated & not self.beforeSave are true.

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

No branches or pull requests

1 participant