Skip to content

Commit 759519a

Browse files
committed
Do not send None arguments to the front-end
1 parent ec0f2aa commit 759519a

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

examples/introduction.ipynb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@
113113
"metadata": {},
114114
"outputs": [],
115115
"source": [
116-
"c.fill_text('Hello World!!', 50, 50, 50)"
116+
"c.fill_text('Hello World!!', 50, 50)"
117117
]
118118
},
119119
{

ipycanvas/canvas.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ def _on_set_attr(self, change):
126126
self._send_command(command)
127127

128128
def _send_canvas_command(self, name, *args):
129-
self._send_command({'name': name, 'args': args})
129+
self._send_command({'name': name, 'args': [arg for arg in args if arg is not None]})
130130

131131
def _send_command(self, command):
132132
if self.caching:

0 commit comments

Comments
 (0)