Updated branch restrictions value data type to accpet null due to API failures for some kinds
Signed-off-by: minto-mathews-carrier <minto.mathews@carrier.com>
This commit is contained in:
committed by
minto-mathews-carrier
parent
d1600abab1
commit
280611d812
@@ -0,0 +1,5 @@
|
||||
---
|
||||
'@backstage/plugin-scaffolder-backend-module-bitbucket-cloud': patch
|
||||
---
|
||||
|
||||
Fix `bitbucketCloudBranchRestrictions` API calls to accept null to prevent 400 errors for some branch restriction kinds defined.
|
||||
+2
-2
@@ -30,7 +30,7 @@ const createBitbucketCloudBranchRestriction = async (opts: {
|
||||
branchMatchKind?: string;
|
||||
branchType?: string;
|
||||
pattern?: string;
|
||||
value?: number;
|
||||
value?: number | null;
|
||||
users?: { uuid: string; type: string }[];
|
||||
groups?: { slug: string; type: string }[];
|
||||
authorization: {
|
||||
@@ -84,7 +84,7 @@ export function createBitbucketCloudBranchRestrictionAction(options: {
|
||||
branchMatchKind?: string;
|
||||
branchType?: string;
|
||||
pattern?: string;
|
||||
value?: number;
|
||||
value?: number | null;
|
||||
users?: { uuid: string }[];
|
||||
groups?: { slug: string }[];
|
||||
token?: string;
|
||||
|
||||
@@ -213,6 +213,7 @@ const restriction = {
|
||||
description:
|
||||
'The value of the restriction. This field is required when kind is one of require_approvals_to_merge / require_default_reviewer_approvals_to_merge / require_passing_builds_to_merge / require_commits_behind.',
|
||||
type: 'number',
|
||||
nullable: true,
|
||||
},
|
||||
users: {
|
||||
title: 'users',
|
||||
|
||||
Reference in New Issue
Block a user