We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 169715e commit 68c696aCopy full SHA for 68c696a
opentok/session.py
@@ -1,3 +1,6 @@
1
+from six import text_type, u
2
+from .exceptions import OpenTokException
3
+
4
class Session(object):
5
"""
6
Represents an OpenTok session.
@@ -8,6 +11,8 @@ class Session(object):
8
11
:ivar String session_id: The session ID.
9
12
10
13
def __init__(self, sdk, session_id, **kwargs):
14
+ if not text_type(session_id):
15
+ raise OpenTokException(u('Cannot instantiate Session, session_id was not valid {0}').format(session_id))
16
self.session_id = session_id
17
self.sdk = sdk
18
for key, value in kwargs.items():
0 commit comments