Initialize & send forceHttpBasicAuth & enableOCI params correctly during repo update from UI (#16794)

This commit is contained in:
Siddhesh Ghadi 2024-01-19 20:44:38 +05:30 committed by GitHub
parent 80683acb71
commit 32e373829b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 8 additions and 3 deletions

View file

@ -65,7 +65,8 @@ export const RepoDetails = (props: {repo: models.Repository; save?: (params: New
enableLfs: repo.enableLfs || false,
proxy: repo.proxy || '',
project: repo.project || '',
enableOCI: repo.enableOCI || false
enableOCI: repo.enableOCI || false,
forceHttpBasicAuth: repo.forceHttpBasicAuth || false
};
return (

View file

@ -62,7 +62,9 @@ export class RepositoriesService {
insecure,
enableLfs,
proxy,
project
project,
forceHttpBasicAuth,
enableOCI
}: {
type: string;
name: string;
@ -75,10 +77,12 @@ export class RepositoriesService {
enableLfs: boolean;
proxy: string;
project?: string;
forceHttpBasicAuth?: boolean;
enableOCI: boolean;
}): Promise<models.Repository> {
return requests
.put(`/repositories/${encodeURIComponent(url)}`)
.send({type, name, repo: url, username, password, tlsClientCertData, tlsClientCertKey, insecure, enableLfs, proxy, project})
.send({type, name, repo: url, username, password, tlsClientCertData, tlsClientCertKey, insecure, enableLfs, proxy, project, forceHttpBasicAuth, enableOCI})
.then(res => res.body as models.Repository);
}