Changeset 1395 for pykota

Show
Ignore:
Timestamp:
03/09/04 09:05:27 (21 years ago)
Author:
jalet
Message:

Small fix : only keeps existing quota entries when searching parents

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • pykota/trunk/pykota/storage.py

    r1376 r1395  
    2222# 
    2323# $Log$ 
     24# Revision 1.50  2004/03/09 08:05:27  jalet 
     25# Small fix : only keeps existing quota entries when searching parents 
     26# 
    2427# Revision 1.49  2004/03/01 15:06:51  jalet 
    2528# Pre and Post hooks should now work in the pykota filter too. 
     
    617620        upquotas = [ ] 
    618621        for printer in self.getParentPrinters(userpquota.Printer) : 
    619             upquotas.append(self.getUserPQuota(userpquota.User, printer)) 
     622            upq = self.getUserPQuota(userpquota.User, printer) 
     623            if upq.Exists : 
     624                upquotas.append(upq) 
    620625        return upquotas         
    621626         
     
    624629        gpquotas = [ ] 
    625630        for printer in self.getParentPrinters(grouppquota.Printer) : 
    626             gpquotas.append(self.getGroupPQuota(grouppquota.Group, printer)) 
     631            gpq = self.getGroupPQuota(grouppquota.Group, printer) 
     632            if gpq.Exists : 
     633                gpquotas.append(gpq) 
    627634        return gpquotas         
    628635