diff options
author | Denys Mishunov <dmishunov@gitlab.com> | 2019-07-03 14:14:44 +0200 |
---|---|---|
committer | Denys Mishunov <dmishunov@gitlab.com> | 2019-07-05 15:37:33 +0200 |
commit | ff1a4a4241f1628491a1aec05b440ff650ba66ad (patch) | |
tree | bd2cf63f652d1cfc911c1e98b8c41bc414b81c75 /app/assets/javascripts/ide/components/repo_editor.vue | |
parent | 4c954a5c9e54e768aaca0eb787d8d9d2f63ebcae (diff) | |
download | gitlab-ce-ff1a4a4241f1628491a1aec05b440ff650ba66ad.tar.gz |
Initiate editor for any file without content60856-deleting-binary-file
Important to get file data for any file that has no content set yet: we
need this information in order to build a previe for changed/staged
files if they were not yet opened in the editor
Diffstat (limited to 'app/assets/javascripts/ide/components/repo_editor.vue')
-rw-r--r-- | app/assets/javascripts/ide/components/repo_editor.vue | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/app/assets/javascripts/ide/components/repo_editor.vue b/app/assets/javascripts/ide/components/repo_editor.vue index 5fcb11a232e..03756a634d5 100644 --- a/app/assets/javascripts/ide/components/repo_editor.vue +++ b/app/assets/javascripts/ide/components/repo_editor.vue @@ -144,7 +144,9 @@ export default { 'triggerFilesChange', ]), initEditor() { - if (this.shouldHideEditor) return; + if (this.shouldHideEditor && (this.file.content || this.file.raw)) { + return; + } this.editor.clearEditor(); |