From adb8055f0871b17eeec912e4f319f9288e8aae9b Mon Sep 17 00:00:00 2001 From: Athanasius Date: Mon, 31 Jan 2022 15:22:36 +0000 Subject: [PATCH] Inara: Be paranoid in case of -ve credits balance --- plugins/inara.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/inara.py b/plugins/inara.py index abc45d5e..08b3b86d 100644 --- a/plugins/inara.py +++ b/plugins/inara.py @@ -1363,7 +1363,7 @@ def cmdr_data(data: CAPIData, is_beta): # noqa: CCR001 if config.get_int('inara_out') and not is_beta and not this.multicrew and credentials(this.cmdr): if ( abs(this.last_credits - data['commander']['credits']) >= - min(this.last_credits * CREDITS_DELTA_MIN_FRACTION, CREDITS_DELTA_MIN_ABSOLUTE) + min(abs(this.last_credits * CREDITS_DELTA_MIN_FRACTION), CREDITS_DELTA_MIN_ABSOLUTE) ): this.filter_events( Credentials(this.cmdr, this.FID, str(credentials(this.cmdr))),