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
Léo-Paul Géneau
gitlab-ce
Commits
b85f2fa4
Commit
b85f2fa4
authored
Apr 25, 2017
by
Bob Van Landuyt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Clear html cache for a projects milestones
parent
ce0102d8
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
0 deletions
+14
-0
lib/gitlab/database/rename_reserved_paths_migration/v1/rename_base.rb
...atabase/rename_reserved_paths_migration/v1/rename_base.rb
+4
-0
spec/lib/gitlab/database/rename_reserved_paths_migration/v1/rename_base_spec.rb
...se/rename_reserved_paths_migration/v1/rename_base_spec.rb
+10
-0
No files found.
lib/gitlab/database/rename_reserved_paths_migration/v1/rename_base.rb
View file @
b85f2fa4
...
@@ -107,6 +107,10 @@ module Gitlab
...
@@ -107,6 +107,10 @@ module Gitlab
update_column_in_batches
(
:notes
,
:note_html
,
nil
)
do
|
table
,
query
|
update_column_in_batches
(
:notes
,
:note_html
,
nil
)
do
|
table
,
query
|
query
.
where
(
table
[
:project_id
].
in
(
project_ids
))
query
.
where
(
table
[
:project_id
].
in
(
project_ids
))
end
end
update_column_in_batches
(
:milestones
,
:description_html
,
nil
)
do
|
table
,
query
|
query
.
where
(
table
[
:project_id
].
in
(
project_ids
))
end
end
end
def
file_storage?
def
file_storage?
...
...
spec/lib/gitlab/database/rename_reserved_paths_migration/v1/rename_base_spec.rb
View file @
b85f2fa4
...
@@ -65,6 +65,16 @@ describe Gitlab::Database::RenameReservedPathsMigration::V1::RenameBase do
...
@@ -65,6 +65,16 @@ describe Gitlab::Database::RenameReservedPathsMigration::V1::RenameBase do
expect
(
note
.
reload
.
note_html
).
to
be_nil
expect
(
note
.
reload
.
note_html
).
to
be_nil
end
end
it
'removes milestone description'
do
milestone
=
create
(
:milestone
,
project:
project
,
description_html:
'milestone description'
)
subject
.
remove_cached_html_for_projects
([
project
.
id
])
expect
(
milestone
.
reload
.
description_html
).
to
be_nil
end
end
end
describe
'#rename_path_for_routable'
do
describe
'#rename_path_for_routable'
do
...
...
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