diff --git a/services/web/public/coffee/ide/history/controllers/HistoryV2DiffController.coffee b/services/web/public/coffee/ide/history/controllers/HistoryV2DiffController.coffee index 89cf3975ec..c2ced4cf59 100644 --- a/services/web/public/coffee/ide/history/controllers/HistoryV2DiffController.coffee +++ b/services/web/public/coffee/ide/history/controllers/HistoryV2DiffController.coffee @@ -29,10 +29,11 @@ define [ do tryOpen = () -> if iterations > 5 return + iterations += 1 entity = ide.fileTreeManager.findEntityById(id) if entity? and type == 'doc' ide.editorManager.openDoc(entity) - if entity? and type == 'file' + else if entity? and type == 'file' ide.binaryFilesManager.openFile(entity) else setTimeout(tryOpen, 500)