Skip to content

Commit 9a0f178

Browse files
author
Joel Collins
committed
Added sets to JSON encoder
1 parent 69bee24 commit 9a0f178

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

labthings/server/representations.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ class LabThingsJSONEncoder(JSONEncoder):
1010
"""
1111

1212
def default(self, o):
13+
if isinstance(o, set):
14+
return list(o)
1315
return JSONEncoder.default(self, o)
1416

1517

0 commit comments

Comments
 (0)