aboutsummaryrefslogtreecommitdiffhomepage
path: root/libs/python_anticaptcha/compat.py
blob: c0c5c6f937365360431c9fcac2a80a09abdb05bc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
import six

if six.PY3:

    def split(value, sep, maxsplit):
        return value.split(sep, maxsplit=maxsplit)


else:

    def split(value, sep, maxsplit):
        parts = value.split(sep)
        return parts[:maxsplit] + [
            sep.join(parts[maxsplit:]),
        ]