File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
atlassian/bitbucket/cloud/repositories Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -32,22 +32,26 @@ def create(
32
32
33
33
return self ._get_object (self .post (None , data ))
34
34
35
- def each (self , q = None , sort = None ):
35
+ def each (self , q = None , sort = None , pagelen = None ):
36
36
"""
37
37
Returns the list of refs in this repository.
38
38
39
39
:param q: string: Query string to narrow down the response.
40
40
See https://developer.atlassian.com/bitbucket/api/2/reference/meta/filtering for details.
41
41
:param sort: string: Name of a response property to sort results.
42
42
See https://developer.atlassian.com/bitbucket/api/2/reference/meta/filtering for details.
43
-
43
+ :param pagelen: int: Name of a response property to change page size.
44
+ See https://developer.atlassian.com/cloud/bitbucket/rest/intro/#pagination for details.
45
+
44
46
:return: A generator for the Ref objects
45
47
"""
46
48
params = {}
47
49
if sort is not None :
48
50
params ["sort" ] = sort
49
51
if q is not None :
50
52
params ["q" ] = q
53
+ if pagelen is not None :
54
+ params ["pagelen" ] = q
51
55
for ref in self ._get_paged (None , trailing = True , params = params ):
52
56
yield self ._get_object (super (Refs , self ).get (ref .get ("name" )))
53
57
You can’t perform that action at this time.
0 commit comments