Skip to content

Commit 6d2112b

Browse files
committed
Fix regex refactor bug
1 parent 740ff6f commit 6d2112b

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

webexteamssdk/api/memberships.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -248,4 +248,4 @@ def delete(self, membershipId):
248248
check_type(membershipId, basestring)
249249

250250
# API request
251-
self._session.delete(API_ENDPOINT + '/' + membershipId, optional=True)
251+
self._session.delete(API_ENDPOINT + '/' + membershipId)

webexteamssdk/api/messages.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -177,16 +177,16 @@ def create(self, roomId=None, toPersonId=None, toPersonEmail=None,
177177
check_type(text, basestring, optional=True)
178178
check_type(markdown, basestring, optional=True)
179179
check_type(files, list, optional=True)
180-
check_type(attachments, list)
180+
check_type(attachments, list, optional=True)
181181
if files:
182182
if len(files) != 1:
183183
raise ValueError("The length of the `files` list is greater "
184-
"than one (1, optional=True). The files parameter is a "
184+
"than one (1). The files parameter is a "
185185
"list, which accepts multiple values to "
186186
"allow for future expansion, but currently "
187187
"only one file may be included with the "
188188
"message.")
189-
check_type(files[0], basestring, optional=True)
189+
check_type(files[0], basestring)
190190

191191
if attachments:
192192
for attachment in attachments:

webexteamssdk/restsession.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -161,12 +161,12 @@ def single_request_timeout(self):
161161
@single_request_timeout.setter
162162
def single_request_timeout(self, value):
163163
"""The timeout (seconds) for a single HTTP REST API request."""
164-
check_type(value, int)
164+
check_type(value, int, optional=True)
165165
assert value is None or value > 0
166166
self._single_request_timeout = value
167167

168168
@property
169-
def wait_on_rate_limit(self, optional=True):
169+
def wait_on_rate_limit(self):
170170
"""Automatic rate-limit handling.
171171
172172
This setting enables or disables automatic rate-limit handling. When

0 commit comments

Comments
 (0)