modify return content type

上级 fc6ddce8
......@@ -863,9 +863,7 @@ paths:
200:
description: "返回格式"
schema:
type: "array"
items:
$ref: "#/definitions/Content"
$ref: "#/definitions/Content"
post:
tags:
- "Repositories"
......
......@@ -973,7 +973,7 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **GetV5ReposOwnerRepoContentsPath**
> []Content GetV5ReposOwnerRepoContentsPath(ctx, owner, repo, path, optional)
> Content GetV5ReposOwnerRepoContentsPath(ctx, owner, repo, path, optional)
获取仓库具体路径下的内容
获取仓库具体路径下的内容
......@@ -1001,7 +1001,7 @@ Name | Type | Description | Notes
### Return type
[**[]Content**](Content.md)
[**Content**](Content.md)
### Authorization
......
......@@ -2244,7 +2244,7 @@ RepositoriesApiService 获取仓库具体路径下的内容
* @param "AccessToken" (optional.String) - 用户授权码
* @param "Ref" (optional.String) - 分支、tag或commit。默认: 仓库的默认分支(通常是master)
@return []Content
@return Content
*/
type GetV5ReposOwnerRepoContentsPathOpts struct {
......@@ -2252,13 +2252,13 @@ type GetV5ReposOwnerRepoContentsPathOpts struct {
Ref optional.String
}
func (a *RepositoriesApiService) GetV5ReposOwnerRepoContentsPath(ctx context.Context, owner string, repo string, path string, localVarOptionals *GetV5ReposOwnerRepoContentsPathOpts) ([]Content, *http.Response, error) {
func (a *RepositoriesApiService) GetV5ReposOwnerRepoContentsPath(ctx context.Context, owner string, repo string, path string, localVarOptionals *GetV5ReposOwnerRepoContentsPathOpts) (Content, *http.Response, error) {
var (
localVarHttpMethod = strings.ToUpper("Get")
localVarPostBody interface{}
localVarFileName string
localVarFileBytes []byte
localVarReturnValue []Content
localVarReturnValue Content
)
// create path and map variables
......@@ -2325,7 +2325,7 @@ func (a *RepositoriesApiService) GetV5ReposOwnerRepoContentsPath(ctx context.Con
}
if localVarHttpResponse.StatusCode == 200 {
var v []Content
var v Content
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"))
if err != nil {
newErr.error = err.Error()
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册