summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
Diffstat (limited to 'docs')
-rw-r--r--docs/howto/custom-lookups.txt2
1 files changed, 1 insertions, 1 deletions
diff --git a/docs/howto/custom-lookups.txt b/docs/howto/custom-lookups.txt
index 2a7ae4a5e5..59f3d30e2d 100644
--- a/docs/howto/custom-lookups.txt
+++ b/docs/howto/custom-lookups.txt
@@ -312,7 +312,7 @@ would override ``get_lookup`` with something like::
def get_lookup(self, lookup_name):
if lookup_name.startswith('x'):
try:
- dimension = int(lookup_name[1:])
+ dimension = int(lookup_name.removeprefix("x"))
except ValueError:
pass
else: