testmycode/tmc-server

View on GitHub
app/controllers/api/beta/course_id_information_controller.rb

Summary

Maintainability
A
0 mins
Test Coverage
# frozen_string_literal: true

class Api::Beta::CourseIdInformationController < Api::Beta::BaseController
  before_action :doorkeeper_authorize!, scopes: [:public]

  def index
    course_ids = Course.order(:id).where(hidden: false).enabled.pluck(:id)
    present(course_ids)
  end
end