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
41096704
Commit
41096704
authored
Jul 10, 2018
by
Rubén Dávila
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix clonflicts for lib/gitlab/git_access.rb and spec/lib/gitlab/git_access_spec.rb
parent
359cfcc7
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
0 additions
and
18 deletions
+0
-18
lib/gitlab/git_access.rb
lib/gitlab/git_access.rb
+0
-15
spec/lib/gitlab/git_access_spec.rb
spec/lib/gitlab/git_access_spec.rb
+0
-3
No files found.
lib/gitlab/git_access.rb
View file @
41096704
...
...
@@ -2,12 +2,9 @@
# class return an instance of `GitlabAccessStatus`
module
Gitlab
class
GitAccess
<<<<<<<
HEAD
prepend
::
EE
::
Gitlab
::
GitAccess
include
ActionView
::
Helpers
::
SanitizeHelper
include
PathLocksHelper
=======
>>>>>>>
upstream
/
master
include
Gitlab
::
Utils
::
StrongMemoize
UnauthorizedError
=
Class
.
new
(
StandardError
)
...
...
@@ -228,10 +225,7 @@ module Gitlab
end
end
<<<<<<<
HEAD
# TODO: please clean this up
=======
>>>>>>>
upstream
/
master
def
check_push_access!
if
project
.
repository_read_only?
raise
UnauthorizedError
,
ERROR_MESSAGES
[
:read_only
]
...
...
@@ -249,7 +243,6 @@ module Gitlab
return
if
changes
.
blank?
# Allow access this is needed for EE.
<<<<<<<
HEAD
if
check_size_limit?
&&
project
.
above_size_limit?
raise
UnauthorizedError
,
Gitlab
::
RepositorySizeError
.
new
(
project
).
push_error
end
...
...
@@ -259,8 +252,6 @@ module Gitlab
raise
UnauthorizedError
,
strip_tags
(
message
)
end
=======
>>>>>>>
upstream
/
master
check_change_access!
end
...
...
@@ -270,11 +261,8 @@ module Gitlab
# clear stale lock files.
project
.
repository
.
clean_stale_repository_files
<<<<<<<
HEAD
push_size_in_bytes
=
0
=======
>>>>>>>
upstream
/
master
# Iterate over all changes to find if user allowed all of them to be applied
changes_list
.
each
.
with_index
do
|
change
,
index
|
first_change
=
index
==
0
...
...
@@ -381,7 +369,6 @@ module Gitlab
protected
<<<<<<<
HEAD
def
check_size_limit?
strong_memoize
(
:check_size_limit
)
do
changes_list
.
any?
do
|
change
|
...
...
@@ -390,8 +377,6 @@ module Gitlab
end
end
=======
>>>>>>>
upstream
/
master
def
changes_list
@changes_list
||=
Gitlab
::
ChangesList
.
new
(
changes
)
end
...
...
spec/lib/gitlab/git_access_spec.rb
View file @
41096704
...
...
@@ -779,7 +779,6 @@ describe Gitlab::GitAccess do
aggregate_failures
do
matrix
.
each
do
|
action
,
allowed
|
check
=
->
{
push_changes
(
changes
[
action
])
}
<<<<<<<
HEAD
if
allowed
expect
(
&
check
).
not_to
raise_error
,
...
...
@@ -805,8 +804,6 @@ describe Gitlab::GitAccess do
aggregate_failures
do
matrix
.
each
do
|
action
,
allowed
|
check
=
->
{
push_changes
(
changes
[
action
])
}
=======
>>>>>>>
upstream
/
master
if
allowed
expect
(
&
check
).
not_to
raise_error
,
...
...
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