@@ -67,7 +67,7 @@ import { readFields } from '../metadata-admin/previews/object-fields-io.js';
6767import { t , tFormat , type SupportedLocale } from '../metadata-admin/i18n.js' ;
6868import { cbpMasterDetailDefaultsRequired , deriveMasterObject , requireCbpMasterDetails } from './owd-sharing.js' ;
6969import { toast } from 'sonner' ;
70- import { draftReceiptVersion , type DraftPin , useDraftSaveGuard } from '../metadata-admin/DraftConflictDialog.js' ;
70+ import { type DraftPin , useDraftSaveGuard } from '../metadata-admin/DraftConflictDialog.js' ;
7171import {
7272 STUDIO_SAVE_TOAST_ID ,
7373 publishSavedItem ,
@@ -509,18 +509,15 @@ export function PackageOwdOverviewPanel({
509509 // runtime resolved from the list; the authoring door refuses the two
510510 // together, for the whole object. So the resolved `options` stay out of
511511 // the body, on every bound field and on nothing else.
512- // objectstack#37440 — the version this row's own draft write returned, which pins its publish.
513- let draftVersion : string | undefined ;
514512 try {
515- const receipt = await client . save ( 'object' , s . row . name , dropServedPicklistOptions ( next ) , {
513+ await client . save ( 'object' , s . row . name , dropServedPicklistOptions ( next ) , {
516514 mode : 'draft' ,
517515 packageId,
518516 surface : 'studio' ,
519517 // objectstack#27458 — forced only after the author confirmed the
520518 // prerequisite below, and only on the rows that carry one.
521519 ...( force && relations . length > 0 ? { force : true } : { } ) ,
522520 } ) ;
523- draftVersion = draftReceiptVersion ( receipt ) ;
524521 } catch ( e ) {
525522 // objectstack#27458 — making the relationship required is a change
526523 // the server's destructive-change guard asks to confirm (409). Name
@@ -554,7 +551,7 @@ export function PackageOwdOverviewPanel({
554551 recordPublished ( 'object' , s . row . name , packageId , editPinsRef . current . get ( s . row . name ) ?? null ) ;
555552 const live = await publishSavedItem (
556553 client ,
557- { type : 'object' , name : s . row . name , packageId, draftVersion } ,
554+ { type : 'object' , name : s . row . name , packageId } ,
558555 s . row . hasDraft ,
559556 publishPinned ,
560557 ) ;
0 commit comments