DEV: Use the only option when returning groups as json (#296)

This commit is contained in:
Jan Cernik
2024-06-26 16:43:11 -03:00
committed by GitHub
parent e8beeca5c5
commit 489aacf156
@@ -44,7 +44,7 @@ module ::DiscourseDataExplorer
end
def groups
render json: Group.all.select(:id, :name), root: false
render json: Group.all.select(:id, :name).as_json(only: %i[id name]), root: false
end
def group_reports_index