Merge pull request #874 from oddstr13/pr-cleanup-2

Remove unused function compare_version
This commit is contained in:
Odd Stråbø 2024-06-10 06:36:21 +02:00 committed by GitHub
commit f4ffe69ea5
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 0 additions and 20 deletions

View file

@ -16,7 +16,6 @@ from .utils import validate_bluray_dir
from .utils import validate_dvd_dir
from .utils import values
from .utils import JSONRPC
from .utils import compare_version
from .utils import unzip
from .utils import create_id
from .utils import convert_to_local as Local

View file

@ -10,7 +10,6 @@ import sys
import re
import unicodedata
from uuid import uuid4
from distutils.version import LooseVersion
from dateutil import tz, parser
from six import text_type, string_types, iteritems, ensure_text, ensure_binary
@ -106,24 +105,6 @@ def create_id():
return uuid4()
def compare_version(a, b):
''' -1 a is smaller
1 a is larger
0 equal
'''
a = LooseVersion(a)
b = LooseVersion(b)
if a < b:
return -1
if a > b:
return 1
return 0
def find(dict, item):
''' Find value in dictionary.