diff --git a/app/controllers/api/v1/base_controller.rb b/app/controllers/api/v1/base_controller.rb index 6bb5a0ead..407ae411b 100644 --- a/app/controllers/api/v1/base_controller.rb +++ b/app/controllers/api/v1/base_controller.rb @@ -72,6 +72,6 @@ class Api::V1::BaseController < ApplicationController end def verification_with_setting(key) - return render_forbidden unless EduSetting.get(key).split(",").include?(current_user.id.to_s) + return render_error("您没有该权限") unless EduSetting.get(key).split(",").include?(current_user.id.to_s) end end \ No newline at end of file diff --git a/app/controllers/api/v1/projects/code_checks_controller.rb b/app/controllers/api/v1/projects/code_checks_controller.rb index d39419cfd..131b2e80b 100644 --- a/app/controllers/api/v1/projects/code_checks_controller.rb +++ b/app/controllers/api/v1/projects/code_checks_controller.rb @@ -7,7 +7,7 @@ class Api::V1::Projects::CodeChecksController < Api::V1::BaseController @client = Api::V1::Projects::CodecheckService.new(@project) end def index - + render_ok end def create @result = @client.create_task(params["branch"])