workspace: Prevent user from undoing persistent session deserialization (#25106)

Closes #21846

Release Notes:

- Fixed a bug that made it possible to undo changes in dirty
deserialized buffer (with `restore_unsaved_buffers: true`)
f606b0641ePiotr Osiewicz committed on 2/18/2025, 7:49:39 PM· committed by GitHubparente5d8bd2
1 file changedLine totals unavailable