perf: Don't update list view settings on every query (#31743)

It literally doesn't do anything ever.

User settings are explicitly updated using `user_settings.save` endpoint.
This commit is contained in:
Ankush Menat 2025-03-16 11:05:39 +05:30 committed by GitHub
parent 445f3cb5a9
commit 3bfc9fa8da
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1142,6 +1142,10 @@ class DatabaseQuery:
def update_user_settings(self):
# update user settings if new search
if not self.save_user_settings_fields and not getattr(self, "user_settings", None):
# Nothing has changed or needs to be changed
return
user_settings = json.loads(get_user_settings(self.doctype))
if hasattr(self, "user_settings"):