Arthur de Jong

Open Source / Free Software developer

summaryrefslogtreecommitdiffstats
path: root/stdnum/nl/bsn.py
diff options
context:
space:
mode:
authorArthur de Jong <arthur@arthurdejong.org>2012-02-04 20:11:10 +0100
committerArthur de Jong <arthur@arthurdejong.org>2012-02-04 20:11:10 +0100
commitb43817cac49209181cc07cb2dd51e603492f459c (patch)
tree5395153d095a219eed05645bfd36ff8038ec69ad /stdnum/nl/bsn.py
parent548f129e5da9855ca5bdf2f2cfec33c565a54562 (diff)
rename calc_checksum() to checksum() for consistency
git-svn-id: http://arthurdejong.org/svn/python-stdnum/python-stdnum@98 9dea7c4f-944c-4273-ac1a-574ede026edc
Diffstat (limited to 'stdnum/nl/bsn.py')
-rw-r--r--stdnum/nl/bsn.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/stdnum/nl/bsn.py b/stdnum/nl/bsn.py
index 2261d58..e73dda3 100644
--- a/stdnum/nl/bsn.py
+++ b/stdnum/nl/bsn.py
@@ -39,7 +39,7 @@ def compact(number):
return (9 - len(number)) * '0' + number
-def calc_checksum(number):
+def checksum(number):
"""Calculate the checksum over the number."""
return (sum((9 - i) * int(number[i]) for i in range(8)) -
int(number[8])) % 11
@@ -55,7 +55,7 @@ def is_valid(number):
return len(number) == 9 and \
number.isdigit() and \
int(number) > 0 and \
- calc_checksum(number) == 0
+ checksum(number) == 0
def format(number):