Skip to content
This repository has been archived by the owner on Aug 19, 2020. It is now read-only.

Commit

Permalink
recc. from 2to3
Browse files Browse the repository at this point in the history
  • Loading branch information
dangunter committed May 13, 2015
1 parent 34c015e commit 76bffad
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/data_api/kbase_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -124,10 +124,10 @@ def insert_sync(self, obj, **kw):

def search_sync(self, spec, **kw):
result = []
if spec and spec.has_key('oid'):
if spec and 'oid' in spec:
oid = spec['oid']
result = filter(lambda o: getattr(o, 'oid', None) == oid,
map(itemgetter(0), self.objlist))
result = [o for o in map(itemgetter(0), self.objlist) if
getattr(o, 'oid', None) == oid]
return result

def load_bytes(self, f):
Expand Down

0 comments on commit 76bffad

Please sign in to comment.