mirror of
https://github.com/pretix/pretix.git
synced 2026-05-06 15:24:02 +00:00
Use config.getboolean to get metrics enabled value (#770)
Given the following configuration: [metrics] enabled=False Using config.get results in a METRICS_ENABLED value that always evaluates to True. This PR switches to config.getboolean so that metrics can be disabled without deleting the configuration values.
This commit is contained in:
committed by
Raphael Michel
parent
a68686cb06
commit
aecb536a34
@@ -121,7 +121,7 @@ EMAIL_SUBJECT_PREFIX = '[pretix] '
|
||||
|
||||
ADMINS = [('Admin', n) for n in config.get('mail', 'admins', fallback='').split(",") if n]
|
||||
|
||||
METRICS_ENABLED = config.get('metrics', 'enabled', fallback=False)
|
||||
METRICS_ENABLED = config.getboolean('metrics', 'enabled', fallback=False)
|
||||
METRICS_USER = config.get('metrics', 'user', fallback="metrics")
|
||||
METRICS_PASSPHRASE = config.get('metrics', 'passphrase', fallback="")
|
||||
|
||||
|
||||
Reference in New Issue
Block a user