@@ -65,9 +65,7 @@ export class BitbucketApi implements Disposable {
65
65
owner : string ,
66
66
repo : string ,
67
67
branch : string ,
68
- options : {
69
- baseUrl : string ;
70
- } ,
68
+ baseUrl : string ,
71
69
) : Promise < PullRequest | undefined > {
72
70
const scope = getLogScope ( ) ;
73
71
@@ -79,7 +77,7 @@ export class BitbucketApi implements Disposable {
79
77
} > (
80
78
provider ,
81
79
token ,
82
- options . baseUrl ,
80
+ baseUrl ,
83
81
`repositories/${ owner } /${ repo } /pullrequests?q=source.branch.name="${ branch } "&fields=%2Bvalues.reviewers,%2Bvalues.participants` ,
84
82
{
85
83
method : 'GET' ,
@@ -100,8 +98,8 @@ export class BitbucketApi implements Disposable {
100
98
owner : string ,
101
99
repo : string ,
102
100
id : string ,
103
- options : {
104
- baseUrl : string ;
101
+ baseUrl : string ,
102
+ options ?: {
105
103
type ?: IssueOrPullRequestType ;
106
104
} ,
107
105
) : Promise < IssueOrPullRequest | undefined > {
@@ -112,7 +110,7 @@ export class BitbucketApi implements Disposable {
112
110
const prResponse = await this . request < BitbucketPullRequest > (
113
111
provider ,
114
112
token ,
115
- options . baseUrl ,
113
+ baseUrl ,
116
114
`repositories/${ owner } /${ repo } /pullrequests/${ id } ?fields=%2Bvalues.reviewers,%2Bvalues.participants` ,
117
115
{
118
116
method : 'GET' ,
@@ -136,7 +134,7 @@ export class BitbucketApi implements Disposable {
136
134
const issueResponse = await this . request < BitbucketIssue > (
137
135
provider ,
138
136
token ,
139
- options . baseUrl ,
137
+ baseUrl ,
140
138
`repositories/${ owner } /${ repo } /issues/${ id } ` ,
141
139
{
142
140
method : 'GET' ,
@@ -172,8 +170,8 @@ export class BitbucketApi implements Disposable {
172
170
token : string ,
173
171
baseUrl : string ,
174
172
route : string ,
175
- options : { method : RequestInit [ 'method' ] } & Record < string , unknown > ,
176
- scope : LogScope | undefined ,
173
+ options ? : { method : RequestInit [ 'method' ] } & Record < string , unknown > ,
174
+ scope ? : LogScope | undefined ,
177
175
cancellation ?: CancellationToken | undefined ,
178
176
) : Promise < T | undefined > {
179
177
const url = `${ baseUrl } /${ route } ` ;
0 commit comments