cartodb-4.42/app/models/permission/permission_group_presenter.rb

16 lines
256 B
Ruby
Raw Normal View History

2024-04-06 13:25:13 +08:00
module CartoDB
class PermissionGroupPresenter
def decorate(group_id)
group = Carto::Group.where(id: group_id).first
return {} if group.nil?
{
id: group.id,
name: group.name
}
end
end
end