aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartin Czygan <martin.czygan@gmail.com>2020-11-04 00:56:10 +0100
committerMartin Czygan <martin.czygan@gmail.com>2020-11-04 00:56:10 +0100
commit713b251a1cdd105e828cb188b8b7789194a99e4c (patch)
tree552e0539d9941b94b7689916655373905633d203
parent6d895108c108d82975f91b61694f86786b6561c6 (diff)
downloadfuzzycat-713b251a1cdd105e828cb188b8b7789194a99e4c.tar.gz
fuzzycat-713b251a1cdd105e828cb188b8b7789194a99e4c.zip
readability
-rw-r--r--fuzzycat/cluster.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/fuzzycat/cluster.py b/fuzzycat/cluster.py
index 3d39a91..075366b 100644
--- a/fuzzycat/cluster.py
+++ b/fuzzycat/cluster.py
@@ -84,7 +84,7 @@ def cut(f=0, sep='\t'):
"""
def func(value):
parts = value.strip().split(sep)
- if len(parts) + 1 < f:
+ if f >= len(parts):
raise ValueError('cannot split value into {} parts'.format(f))
return parts[f]