diff --git a/app/controllers/projects_controller.rb b/app/controllers/projects_controller.rb index e5dc7103a..04982d8ce 100644 --- a/app/controllers/projects_controller.rb +++ b/app/controllers/projects_controller.rb @@ -65,11 +65,7 @@ class ProjectsController < ApplicationController def verify_auth_token data = Projects::VerifyAuthTokenService.call(params[:clone_addr], params[:auth_token]) - if data - render_ok - else - render_error('token验证不通过') - end + render_ok({data: data}) end def migrate diff --git a/app/services/projects/verify_auth_token_service.rb b/app/services/projects/verify_auth_token_service.rb index 1318bb9db..36dcb106f 100644 --- a/app/services/projects/verify_auth_token_service.rb +++ b/app/services/projects/verify_auth_token_service.rb @@ -7,7 +7,7 @@ class Projects::VerifyAuthTokenService < ApplicationService @repo = nil @owner = nil @website = nil - @success = nil + @success = false end def call