Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix visualization backup when permission does not exist #15874

Merged
merged 1 commit into from
Sep 28, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ Development
* Migrate `::FeatureFlagsUser` to `ActiveRecord` [#15841](https://github.com/CartoDB/cartodb/pull/15841)
* Migrate `::SearchTweet` to ActiveRecord [#15859](https://github.com/CartoDB/cartodb/pull/15859)
* Revamp Rubocop config
* Fix visualization backup when permission is missing [#15874](https://github.com/CartoDB/cartodb/pull/15874)

4.41.1 (2020-09-03)
-------------------
Expand Down
6 changes: 3 additions & 3 deletions app/services/carto/visualizations_export_service_2.rb
Original file line number Diff line number Diff line change
Expand Up @@ -364,9 +364,9 @@ def export_state(state)
end

def export_permission(permission)
{
access_control_list: JSON.parse(permission.access_control_list, symbolize_names: true)
}
access_control_list = []
access_control_list = JSON.parse(permission.access_control_list, symbolize_names: true) if permission
{ access_control_list: access_control_list }
end

def export_syncronization(synchronization)
Expand Down