fixed a bug in the django collection