diff options
author | Sol Jerome <sol.jerome@gmail.com> | 2012-07-31 09:38:30 -0500 |
---|---|---|
committer | Sol Jerome <sol.jerome@gmail.com> | 2012-07-31 09:38:30 -0500 |
commit | ed600413b21805161f300b6f6325851c6f9c6a12 (patch) | |
tree | 28cbf8cafefd9c5c34a5dac28aab1e774f2a98de | |
parent | 838fbf56829cd15182e73e3820a453037afbea38 (diff) | |
download | bcfg2-ed600413b21805161f300b6f6325851c6f9c6a12.tar.gz bcfg2-ed600413b21805161f300b6f6325851c6f9c6a12.tar.bz2 bcfg2-ed600413b21805161f300b6f6325851c6f9c6a12.zip |
Plugin.py: Remove custom sort
This causes problems for PY3K and also appears to be unnecessary as we
already handle priorities in the Specificity class.
Signed-off-by: Sol Jerome <sol.jerome@gmail.com>
-rw-r--r-- | src/lib/Bcfg2/Server/Plugin.py | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/src/lib/Bcfg2/Server/Plugin.py b/src/lib/Bcfg2/Server/Plugin.py index 2a68ea3b7..18d4bb05d 100644 --- a/src/lib/Bcfg2/Server/Plugin.py +++ b/src/lib/Bcfg2/Server/Plugin.py @@ -1068,7 +1068,7 @@ class EntrySet(Debuggable): gspec = [ent for ent in matching if ent.specific.group] if gspec: - gspec.sort(self.group_sortfunc) + gspec.sort() return gspec[-1] aspec = [ent for ent in matching if ent.specific.all] @@ -1174,10 +1174,6 @@ class EntrySet(Debuggable): elif event.filename in [':info', 'info']: self.metadata = default_file_metadata.copy() - def group_sortfunc(self, x, y): - """sort groups by their priority""" - return cmp(x.specific.prio, y.specific.prio) - def bind_info_to_entry(self, entry, metadata): bind_info(entry, metadata, infoxml=self.infoxml, default=self.metadata) |