move import into function to avoid having to add an __all__ list...

This commit is contained in:
Skip Montanaro 2001-03-01 04:13:51 +00:00
parent 59ade08079
commit 58eadbaf12
1 changed files with 2 additions and 2 deletions

View File

@ -1,7 +1,5 @@
"""Guess which db package to use to open a db file."""
import struct
def whichdb(filename):
"""Guess which db package to use to open a db file.
@ -15,6 +13,8 @@ def whichdb(filename):
database using that module may still fail.
"""
import struct
# Check for dbm first -- this has a .pag and a .dir file
try:
f = open(filename + ".pag", "rb")