export: Fix error in import.

This commit is contained in:
Dylan Araps 2017-08-15 19:57:35 +10:00
parent 930b67096a
commit 008bd40f89
2 changed files with 4 additions and 2 deletions

View File

@ -133,7 +133,9 @@ def process_args(args):
if not args.n: if not args.n:
wallpaper.change(colors_plain["wallpaper"]) wallpaper.change(colors_plain["wallpaper"])
colors_plain["font"] = args.fn or "None" if args.fn:
colors_plain["font"] = args.fn
export.every(colors_plain) export.every(colors_plain)
if not args.e: if not args.e:

View File

@ -20,7 +20,7 @@ def flatten_colors(colors):
"""Prepare colors to be exported. """Prepare colors to be exported.
Flatten dicts and convert colors to util.Color()""" Flatten dicts and convert colors to util.Color()"""
all_colors = {"wallpaper": colors["wallpaper"], all_colors = {"wallpaper": colors["wallpaper"],
"font": colors["font"], "font": colors.get("font", "None"),
**colors["special"], **colors["special"],
**colors["colors"]} **colors["colors"]}
return {k: util.Color(v) for k, v in all_colors.items()} return {k: util.Color(v) for k, v in all_colors.items()}