File tree Expand file tree Collapse file tree 1 file changed +1
-11
lines changed
src/vs/workbench/contrib/chat/browser/chatEditing Expand file tree Collapse file tree 1 file changed +1
-11
lines changed Original file line number Diff line number Diff line change @@ -221,17 +221,7 @@ export class ChatEditingCodeEditorIntegration implements IModifiedFileEntryEdito
221
221
this . _store . add ( toDisposable ( restoreActualOptions ) ) ;
222
222
223
223
const shouldBeReadOnly = derived ( this , r => {
224
- const model = codeEditorObs . model . read ( r ) ;
225
- if ( ! model ) {
226
- return false ;
227
- }
228
- for ( const session of chatEditingService . editingSessionsObs . read ( r ) ) {
229
- const entry = session . readEntry ( model . uri , r ) ;
230
- if ( entry ?. isCurrentlyBeingModifiedBy . read ( r ) ) {
231
- return true ;
232
- }
233
- }
234
- return false ;
224
+ return enabledObs . read ( r ) && Boolean ( _entry . isCurrentlyBeingModifiedBy . read ( r ) ) ;
235
225
} ) ;
236
226
237
227
this . _store . add ( autorun ( r => {
You can’t perform that action at this time.
0 commit comments