diff --git a/lightning/visualization.py b/lightning/visualization.py
index e3a0997..a18697c 100644
--- a/lightning/visualization.py
+++ b/lightning/visualization.py
@@ -41,7 +41,7 @@ def _append_image(self, image):
def _append_data(self, data=None, field=None):
payload = {'data': data}
- headers = {'Content-type': 'application/json', 'Accept': 'text/plain'}
+ headers = {'Content-type': 'application/json', 'Accept': 'text/plain'}
url = self.session.host + '/sessions/' + str(self.session.id) + '/visualizations/' + str(self.id) + '/data/'
if field:
url += field
@@ -51,7 +51,7 @@ def _append_data(self, data=None, field=None):
def _update_data(self, data=None, field=None):
payload = {'data': data}
- headers = {'Content-type': 'application/json', 'Accept': 'text/plain'}
+ headers = {'Content-type': 'application/json', 'Accept': 'text/plain'}
url = self.session.host + '/sessions/' + str(self.session.id) + '/visualizations/' + str(self.id) + '/data/'
if field:
url += field
@@ -194,7 +194,7 @@ def save_html(self, filename=None, overwrite=False):
os.remove(filename)
with open(filename, "wb") as f:
f.write(base.encode('utf-8'))
- f.write('')
+ f.write(b'')
@staticmethod
def load_template():
@@ -208,5 +208,3 @@ def load_embed():
location = os.path.join(os.path.dirname(__file__), 'lib/embed.js')
import codecs
return codecs.open(location, "r", "utf-8").read()
-
-