fixes bug in tasklib/database.py