From 9e9b66ea10a04f0b84e329359f1bba6280c091b4 Mon Sep 17 00:00:00 2001 From: Amaan Khan Date: Thu, 2 Feb 2023 20:08:56 +0530 Subject: [PATCH] fix: adds conditional check for api-key's status --- admin/rt-transcoder-handler.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/admin/rt-transcoder-handler.php b/admin/rt-transcoder-handler.php index 8186c8c..6a81cb9 100755 --- a/admin/rt-transcoder-handler.php +++ b/admin/rt-transcoder-handler.php @@ -650,7 +650,7 @@ public function usage_widget() { } if ( ! empty( $api_key ) ) { - if ( $usage_details && isset( $usage_details[ $api_key ]->status ) && $usage_details[ $api_key ]->status ) { + if ( $usage_details && isset( $usage_details[ $api_key ]->status ) && $usage_details[ $api_key ]->status && 'error' !== $usage_details[ $api_key ]->status ) { if ( isset( $usage_details[ $api_key ]->plan->name ) ) { $plan_name = strtolower( $usage_details[ $api_key ]->plan->name );