summaryrefslogtreecommitdiff
path: root/lib/gitlab/import_export/project_tree_restorer.rb
diff options
context:
space:
mode:
authorBob Van Landuyt <bob@vanlanduyt.co>2018-04-05 12:13:10 +0200
committerBob Van Landuyt <bob@vanlanduyt.co>2018-04-05 15:48:41 +0200
commit902cec12b5b531434ccf7ecf6df22ddb4249c253 (patch)
tree370ebbe5e0f0c49dad5d6b742941fe4a49761568 /lib/gitlab/import_export/project_tree_restorer.rb
parente3acc982a87d8d694690c928cf5ca792218c1782 (diff)
downloadgitlab-ce-902cec12b5b531434ccf7ecf6df22ddb4249c253.tar.gz
Don't export `Project#description_html`
Since we can regenerate `description_html` from the `description`, we should not export it. This avoids some complexity when overriding the description during an import/export where we would need to invalidate this cached field. Now we refresh the markdown cache after the import
Diffstat (limited to 'lib/gitlab/import_export/project_tree_restorer.rb')
-rw-r--r--lib/gitlab/import_export/project_tree_restorer.rb8
1 files changed, 1 insertions, 7 deletions
diff --git a/lib/gitlab/import_export/project_tree_restorer.rb b/lib/gitlab/import_export/project_tree_restorer.rb
index fb37e728485..2c315207298 100644
--- a/lib/gitlab/import_export/project_tree_restorer.rb
+++ b/lib/gitlab/import_export/project_tree_restorer.rb
@@ -83,13 +83,7 @@ module Gitlab
end
def restore_project
- params = project_params.symbolize_keys
-
- if params[:description].present?
- params[:description_html] = nil
- end
-
- @project.update_columns(params)
+ @project.update_columns(project_params)
@project
end