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
94301977
Commit
94301977
authored
Jan 10, 2020
by
charlieablett
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix typo "available"
parent
df64d5d2
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
4 deletions
+4
-4
app/graphql/mutations/snippets/create.rb
app/graphql/mutations/snippets/create.rb
+1
-1
ee/spec/helpers/ee/tree_helper_spec.rb
ee/spec/helpers/ee/tree_helper_spec.rb
+1
-1
lib/gitlab/graphql/authorize/authorize_resource.rb
lib/gitlab/graphql/authorize/authorize_resource.rb
+2
-2
No files found.
app/graphql/mutations/snippets/create.rb
View file @
94301977
...
@@ -42,7 +42,7 @@ module Mutations
...
@@ -42,7 +42,7 @@ module Mutations
if
project_path
.
present?
if
project_path
.
present?
project
=
find_project!
(
project_path:
project_path
)
project
=
find_project!
(
project_path:
project_path
)
elsif
!
can_create_personal_snippet?
elsif
!
can_create_personal_snippet?
raise_resource_not_avaiable_error!
raise_resource_not_avai
l
able_error!
end
end
snippet
=
CreateSnippetService
.
new
(
project
,
snippet
=
CreateSnippetService
.
new
(
project
,
...
...
ee/spec/helpers/ee/tree_helper_spec.rb
View file @
94301977
...
@@ -24,7 +24,7 @@ describe TreeHelper do
...
@@ -24,7 +24,7 @@ describe TreeHelper do
end
end
end
end
context
'when file lock is not avaiable'
do
context
'when file lock is not avai
l
able'
do
it
'returns the path information'
do
it
'returns the path information'
do
stub_licensed_features
(
file_locks:
false
)
stub_licensed_features
(
file_locks:
false
)
...
...
lib/gitlab/graphql/authorize/authorize_resource.rb
View file @
94301977
...
@@ -40,7 +40,7 @@ module Gitlab
...
@@ -40,7 +40,7 @@ module Gitlab
def
authorize!
(
object
)
def
authorize!
(
object
)
unless
authorized_resource?
(
object
)
unless
authorized_resource?
(
object
)
raise_resource_not_avaiable_error!
raise_resource_not_avai
l
able_error!
end
end
end
end
...
@@ -63,7 +63,7 @@ module Gitlab
...
@@ -63,7 +63,7 @@ module Gitlab
end
end
end
end
def
raise_resource_not_avaiable_error!
def
raise_resource_not_avai
l
able_error!
raise
Gitlab
::
Graphql
::
Errors
::
ResourceNotAvailable
,
RESOURCE_ACCESS_ERROR
raise
Gitlab
::
Graphql
::
Errors
::
ResourceNotAvailable
,
RESOURCE_ACCESS_ERROR
end
end
end
end
...
...
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