From 20b4fe0c59357a433042732d46e38da9c3d14c3b Mon Sep 17 00:00:00 2001 From: Runxi Yu Date: Sat, 5 Apr 2025 20:26:57 +0800 Subject: database shall no longer be a global variable --- http_handle_repo_upload_pack.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'http_handle_repo_upload_pack.go') diff --git a/http_handle_repo_upload_pack.go b/http_handle_repo_upload_pack.go index 3d9170c..a6580a7 100644 --- a/http_handle_repo_upload_pack.go +++ b/http_handle_repo_upload_pack.go @@ -24,7 +24,7 @@ func (s *server) httpHandleUploadPack(writer http.ResponseWriter, request *http. groupPath, repoName = params["group_path"].([]string), params["repo_name"].(string) - if err := database.QueryRow(request.Context(), ` + if err := s.database.QueryRow(request.Context(), ` WITH RECURSIVE group_path_cte AS ( -- Start: match the first name in the path where parent_group IS NULL SELECT -- cgit v1.2.3