Browse Source

----------------------------------------------------------------------

Modified Files:
 	Utility.py -- commited a mistake. fixed.

 ----------------------------------------------------------------------
main
Joshua Boverhof 21 years ago
parent
commit
4180983c5e
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      Utility.py

+ 2
- 2
Utility.py View File

@@ -556,11 +556,11 @@ DOM = DOM()
class Collection(UserDict): class Collection(UserDict):
"""Helper class for maintaining ordered named collections.""" """Helper class for maintaining ordered named collections."""
default = lambda k: k.name default = lambda k: k.name
def __init__(self, parent, key=Collection.default):
def __init__(self, parent, key=None):
UserDict.__init__(self) UserDict.__init__(self)
self.parent = weakref.ref(parent) self.parent = weakref.ref(parent)
self.list = [] self.list = []
self._func = key
self._func = key or self.default


def __getitem__(self, key): def __getitem__(self, key):
if type(key) is type(1): if type(key) is type(1):


Loading…
Cancel
Save