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
a01bad5c
Commit
a01bad5c
authored
Nov 27, 2019
by
Andreas Brandl
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add mutex to storing column details
parent
f4b7ec94
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
5 deletions
+7
-5
app/models/concerns/ignorable_columns.rb
app/models/concerns/ignorable_columns.rb
+7
-5
No files found.
app/models/concerns/ignorable_columns.rb
View file @
a01bad5c
...
...
@@ -23,12 +23,12 @@ module IgnorableColumns
self
.
ignored_columns
+=
columns
.
flatten
# rubocop:disable Cop/IgnoredColumns
unless
defined?
(
@ignored_columns_details
)
@ignored_columns_details
=
superclass
.
try
(
:ignored_columns_details
)
&
.
dup
||
{}
end
IGNORE_COLUMN_MUTEX
.
synchronize
do
@ignored_columns_details
||=
superclass
.
try
(
:ignored_columns_details
)
&
.
dup
||
{}
columns
.
flatten
.
each
do
|
column
|
@ignored_columns_details
[
column
.
to_sym
]
=
ColumnIgnore
.
new
(
Date
.
parse
(
remove_after
),
remove_with
)
columns
.
flatten
.
each
do
|
column
|
@ignored_columns_details
[
column
.
to_sym
]
=
ColumnIgnore
.
new
(
Date
.
parse
(
remove_after
),
remove_with
)
end
end
end
...
...
@@ -37,5 +37,7 @@ module IgnorableColumns
def
ignored_columns_details
@ignored_columns_details
||
{}
end
IGNORE_COLUMN_MUTEX
=
Mutex
.
new
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