From 5305a74bb22bc39783a722003e907a4c618b083f Mon Sep 17 00:00:00 2001 From: LDericher <40151420+ldericher@users.noreply.github.com> Date: Wed, 4 Aug 2021 03:41:14 +0200 Subject: [PATCH] opt --- fftcg/book.py | 4 +--- fftcg/imageloader.py | 4 ++-- main.py | 2 +- 3 files changed, 4 insertions(+), 6 deletions(-) diff --git a/fftcg/book.py b/fftcg/book.py index bb6133d..4e11a6f 100644 --- a/fftcg/book.py +++ b/fftcg/book.py @@ -1,7 +1,5 @@ import queue -from .imageloader import ImageLoader - class Book: def __init__(self, cards): @@ -10,7 +8,7 @@ class Book: def __get_pages(self, grid): # cards per sheet r, c = grid - capacity = r*c - 1 + capacity = r * c - 1 # flat copy cards = self.__cards diff --git a/fftcg/imageloader.py b/fftcg/imageloader.py index 90c115d..d1c87e5 100644 --- a/fftcg/imageloader.py +++ b/fftcg/imageloader.py @@ -1,10 +1,10 @@ import io import logging -import threading import queue +import threading -from PIL import Image import requests +from PIL import Image class ImageLoader(threading.Thread): diff --git a/main.py b/main.py index 0c6d217..607e98f 100755 --- a/main.py +++ b/main.py @@ -1,7 +1,7 @@ #!/usr/bin/env python3 -from fftcg.opus import Opus from fftcg.imageloader import ImageLoader +from fftcg.opus import Opus def main():