Ver Fonte

maint: `put_table()` copy user data

wangweimin há 4 anos atrás
pai
commit
45d8b9a099
1 ficheiros alterados com 2 adições e 0 exclusões
  1. 2 0
      pywebio/output.py

+ 2 - 0
pywebio/output.py

@@ -420,6 +420,8 @@ def put_table(tdata, header=None, scope=Scope.Current, position=OutputPosition.B
             for row in tdata
         ]
         header = header_
+    else:
+        tdata = [list(i) for i in tdata]  # copy data
 
     if header:
         tdata = [header, *tdata]