fixed issue saving wallpaper metadata when None

This commit is contained in:
Blake Harnden 2019-12-12 12:34:50 -08:00
parent afd2514728
commit 136121ca18

View file

@ -479,8 +479,11 @@ class CoreClient:
def set_metadata(self): def set_metadata(self):
# create canvas data # create canvas data
wallpaper = None
if self.app.canvas.wallpaper_file:
wallpaper = Path(self.app.canvas.wallpaper_file).name
canvas_config = { canvas_config = {
"wallpaper": Path(self.app.canvas.wallpaper_file).name, "wallpaper": wallpaper,
"wallpaper-style": self.app.canvas.scale_option.get(), "wallpaper-style": self.app.canvas.scale_option.get(),
"gridlines": self.app.canvas.show_grid.get(), "gridlines": self.app.canvas.show_grid.get(),
"fit_image": self.app.canvas.adjust_to_dim.get(), "fit_image": self.app.canvas.adjust_to_dim.get(),