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
0
Merge Requests
0
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
Tatuya Kamada
gitlab-ce
Commits
2f7260b4
Commit
2f7260b4
authored
Oct 18, 2016
by
Douglas Barbosa Alexandre
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix max number of permitted priorities per project label
parent
f0ad0cef
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
app/models/project_label.rb
app/models/project_label.rb
+2
-2
No files found.
app/models/project_label.rb
View file @
2f7260b4
class
ProjectLabel
<
Label
NUMBER_OF_PRIORITIES
=
1
MAX_
NUMBER_OF_PRIORITIES
=
1
belongs_to
:project
...
...
@@ -27,7 +27,7 @@ class ProjectLabel < Label
end
def
permitted_numbers_of_priorities
if
priorities
&&
priorities
.
size
>
=
NUMBER_OF_PRIORITIES
if
priorities
&&
priorities
.
size
>
MAX_
NUMBER_OF_PRIORITIES
errors
.
add
(
:priorities
,
'Number of permitted priorities exceeded'
)
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