Skip to content
Snippets Groups Projects

#9035 + #5936 Preserve trailing new lines at the end of file

Closed Ramya Authappan requested to merge github/fork/kylekatarnls/patch-2 into master
1 file
+ 4
1
Compare changes
  • Side-by-side
  • Inline
@@ -17,7 +17,10 @@
.file-content.code
%pre.js-edit-mode-pane#editor
= params[:content] || local_assigns[:blob_data]
- content = params[:content] || local_assigns[:blob_data]
= content
- if content.length && 0 === content[content.length-1].index(/[\r\n]/)
!= "\n"
- if local_assigns[:path]
.js-edit-mode-pane#preview.hide
.center
Loading