Skip to content
This repository was archived by the owner on Dec 20, 2021. It is now read-only.

Commit cef7ac2

Browse files
committed
n param for CurrentUser.fetch_favorites()
1 parent b930f8a commit cef7ac2

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

vrcpy/objects.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -252,17 +252,20 @@ def update_info(self, email=None, status=None,\
252252
self.client.me = CurrentUser(self.client, resp["data"])
253253
return self.client.me
254254

255-
def fetch_favorites(self, t):
255+
def fetch_favorites(self, t, n: int = 100):
256256
'''
257257
Used to get favorites
258258
259259
t, string
260260
FavoriteType
261261
262+
n, integer
263+
Max number of favorites to return (Most that will ever return is 100)
264+
262265
Returns list of Favorite objects
263266
'''
264267

265-
resp = self.client.api.call("/favorites", params={"type": t})
268+
resp = self.client.api.call("/favorites", params={"type": t, "n": n})
266269

267270
f = []
268271
for favorite in resp["data"]:

0 commit comments

Comments
 (0)