Reproduced on master, too.
Open an odb file that contains one or more dialogs in the "Standard" library. Delete all the dialogs. Save. Close file, open file again. All the dialogs are back in the library.
If one deletes one among several dialogs (or more generally n among m with n<m), it works well, the dialog is gone after a save / close / open cycle.
Also if one deletes all dialogs but creates a new dialog, then it works well: only the new dialog is in the library after a save / close / open cycle.
Fixed in master; commit caee685234e87a4509c9aec4f04813714bfaf93d