Ignore:
Timestamp:
20 Nov 2012, 11:16:38 (12 years ago)
Author:
Henrik Bettermann
Message:

Replace 'has_key' by 'in'

Location:
main/waeup.kofa/trunk/src/waeup/kofa/hostels
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.kofa/trunk/src/waeup/kofa/hostels/browser.py

    r9534 r9701  
    150150    def delHostels(self, **data):
    151151        form = self.request.form
    152         if form.has_key('val_id'):
     152        if 'val_id' in form:
    153153            deleted = []
    154154            child_id = form['val_id']
     
    285285    def switchReservations(self, **data):
    286286        form = self.request.form
    287         if form.has_key('val_id'):
     287        if 'val_id' in form:
    288288            child_id = form['val_id']
    289289        else:
     
    315315    def releaseBeds(self, **data):
    316316        form = self.request.form
    317         if form.has_key('val_id'):
     317        if 'val_id' in form:
    318318            child_id = form['val_id']
    319319        else:
  • main/waeup.kofa/trunk/src/waeup/kofa/hostels/hostel.py

    r9448 r9701  
    119119                        bt = u'%s_%s_%s' % (self.special_handling,sex,bt)
    120120                        uid = u'%s_%s_%d_%s' % (self.hostel_id,block,room_nr,bed)
    121                         if self.has_key(uid):
     121                        if uid in self:
    122122                            bed = self[uid]
    123123                            # Renumber remaining beds
Note: See TracChangeset for help on using the changeset viewer.