summaryrefslogtreecommitdiff
path: root/slugify
diff options
context:
space:
mode:
authorVal Neekman <un33kvu@gmail.com>2019-10-20 13:39:51 -0400
committerGitHub <noreply@github.com>2019-10-20 13:39:51 -0400
commit76f327216bc52adc6115eb6d1483405958810c5c (patch)
treee5eb48e5627724062166eeb6e2898f6c0acfd0be /slugify
parentb9db1bc87e3b19c5c63ab7a00b19685b7996de5d (diff)
downloadpython-slugify-76f327216bc52adc6115eb6d1483405958810c5c.tar.gz
Drop support for old python - cleanup - up version (#88)4.0.0
* Drop support for EOL Python 2.6 and 3.2-2.4 (#87) * Drop support for EOL Python 2.6 and 3.2-3.4 * Remove duplicate class * Upgrade Python syntax with pyupgrade * Upgrade PyPy and PyPy3 and test 3.8 beta * up version
Diffstat (limited to 'slugify')
-rw-r--r--slugify/__init__.py2
-rw-r--r--slugify/slugify.py4
2 files changed, 3 insertions, 3 deletions
diff --git a/slugify/__init__.py b/slugify/__init__.py
index b1dfecb..ab72a8e 100644
--- a/slugify/__init__.py
+++ b/slugify/__init__.py
@@ -4,4 +4,4 @@ from .slugify import *
__author__ = 'Val Neekman @ Neekware Inc. [@vneekman]'
__description__ = 'A Python slugify application that also handles Unicode'
-__version__ = '3.0.6'
+__version__ = '4.0.0'
diff --git a/slugify/slugify.py b/slugify/slugify.py
index 6e66ace..4268fd1 100644
--- a/slugify/slugify.py
+++ b/slugify/slugify.py
@@ -62,9 +62,9 @@ def smart_truncate(string, max_length=0, word_boundary=False, separator=' ', sav
if word:
next_len = len(truncated) + len(word)
if next_len < max_length:
- truncated += '{0}{1}'.format(word, separator)
+ truncated += '{}{}'.format(word, separator)
elif next_len == max_length:
- truncated += '{0}'.format(word)
+ truncated += '{}'.format(word)
break
else:
if save_order: