From 56182ba3e5d5a2661f7a3da7b3f2f774474dc66a Mon Sep 17 00:00:00 2001 From: ReenigneArcher <42013603+ReenigneArcher@users.noreply.github.com> Date: Mon, 6 Nov 2023 20:23:17 -0500 Subject: [PATCH] style(typehints): replace string typehints --- plexapi/mixins.py | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/plexapi/mixins.py b/plexapi/mixins.py index ea6a0756b..f3e16c898 100644 --- a/plexapi/mixins.py +++ b/plexapi/mixins.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- from collections import deque from datetime import datetime -from typing import Tuple +from typing import Deque, Set, Tuple, Union from urllib.parse import parse_qsl, quote, quote_plus, unquote, urlencode, urlsplit from plexapi import media, settings, utils @@ -65,11 +65,9 @@ def defaultAdvanced(self): class SmartFilterMixin: """ Mixin for Plex objects that can have smart filters. """ - def _parseFilterGroups( - self, feed: "deque[Tuple[str, str]]", returnOn: "set[str]|None" = None - ) -> dict: + def _parseFilterGroups(self, feed: Deque[Tuple[str, str]], returnOn: Union[Set[str], None] = None) -> dict: """ Parse filter groups from input lines between push and pop. """ - currentFiltersStack: list[dict] = [] + currentFiltersStack = [] # list of dictionaries operatorForStack = None if returnOn is None: returnOn = set("pop")