Skip to content

Commit

Permalink
Use kwargs (#236)
Browse files Browse the repository at this point in the history
  • Loading branch information
tanpinxi authored Mar 7, 2023
1 parent 81ad94e commit 8470953
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions openai/api_resources/abstract/api_resource.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,15 @@ class APIResource(OpenAIObject):
def retrieve(
cls, id, api_key=None, request_id=None, request_timeout=None, **params
):
instance = cls(id, api_key, **params)
instance = cls(id=id, api_key=api_key, **params)
instance.refresh(request_id=request_id, request_timeout=request_timeout)
return instance

@classmethod
def aretrieve(
cls, id, api_key=None, request_id=None, request_timeout=None, **params
):
instance = cls(id, api_key, **params)
instance = cls(id=id, api_key=api_key, **params)
return instance.arefresh(request_id=request_id, request_timeout=request_timeout)

def refresh(self, request_id=None, request_timeout=None):
Expand Down

0 comments on commit 8470953

Please sign in to comment.