Skip to content

Commit

Permalink
Fix pedalboard screenshots for non app usage
Browse files Browse the repository at this point in the history
Signed-off-by: falkTX <[email protected]>
  • Loading branch information
falkTX committed Nov 18, 2023
1 parent 1632868 commit 76b86cb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions mod/screenshot.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
import logging

from tornado.ioloop import IOLoop
from mod.settings import HTML_DIR, DEV_ENVIRONMENT, DEVICE_KEY, CACHE_DIR
from mod.settings import HTML_DIR, DEV_ENVIRONMENT, DEVICE_KEY, CACHE_DIR, APP


def generate_screenshot(bundle_path, callback):
Expand All @@ -24,7 +24,7 @@ def generate_screenshot(bundle_path, callback):
cwd = os.path.abspath(os.path.join(os.path.dirname(__file__), '../'))

# running packaged through cxfreeze
if os.path.isfile(sys.argv[0]):
if APP and os.path.isfile(sys.argv[0]):
cmd = [os.path.join(cwd, 'mod-pedalboard'), 'take_screenshot', bundle_path, HTML_DIR, CACHE_DIR]
if sys.platform == 'win32':
cmd[0] += ".exe"
Expand Down

0 comments on commit 76b86cb

Please sign in to comment.