Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
e653f4c8
Commit
e653f4c8
authored
Dec 09, 2021
by
Eduardo Bonet
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Adding parameter to blob_data
parent
283f0309
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
app/presenters/blob_presenter.rb
app/presenters/blob_presenter.rb
+2
-2
lib/gitlab/diff/file.rb
lib/gitlab/diff/file.rb
+1
-1
No files found.
app/presenters/blob_presenter.rb
View file @
e653f4c8
...
...
@@ -15,7 +15,7 @@ class BlobPresenter < Gitlab::View::Presenter::Delegated
Gitlab
::
Highlight
.
highlight
(
blob
.
path
,
blob_data
,
blob_data
(
to
)
,
language:
blob_language
,
plain:
plain
)
...
...
@@ -27,7 +27,7 @@ class BlobPresenter < Gitlab::View::Presenter::Delegated
highlight
(
plain:
false
)
end
def
blob_data
def
blob_data
(
to
)
@_blob_data
||=
Gitlab
::
Diff
::
CustomDiff
.
transformed_blob_data
(
blob
)
||
limited_blob_data
(
to:
to
)
end
...
...
lib/gitlab/diff/file.rb
View file @
e653f4c8
...
...
@@ -48,7 +48,7 @@ module Gitlab
end
def
use_custom_diff?
strong_memoize
(
:_custom_diff_enabled
)
{
Feature
.
enabled?
(
:jupyter_clean_diffs
,
repository
.
project
,
default_enabled:
true
)
}
strong_memoize
(
:_custom_diff_enabled
)
{
Feature
.
enabled?
(
:jupyter_clean_diffs
,
repository
.
project
,
default_enabled:
true
)
}
end
def
position
(
position_marker
,
position_type: :text
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment