Skip to content

Commit 1a32d92

Browse files
committed
refac
1 parent b2f7ecd commit 1a32d92

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

backend/open_webui/models/notes.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -312,6 +312,9 @@ async def update_note_by_id(
312312
if 'meta' in form_data:
313313
note.meta = {**note.meta, **form_data['meta']}
314314

315+
if not db.is_modified(note) and 'access_grants' not in form_data:
316+
return await self._to_note_model(note, db=db)
317+
315318
if 'access_grants' in form_data:
316319
await AccessGrants.set_access_grants('note', id, form_data['access_grants'], db=db)
317320

0 commit comments

Comments
 (0)