Skip to content

Commit

Permalink
fix TypeError: unorderable types: str() < float()
Browse files Browse the repository at this point in the history
  • Loading branch information
pbauer authored and jensens committed Jun 26, 2018
1 parent d4a8429 commit 854d105
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Products/ZopeVersionControl/VersionHistory.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ def labelVersion(self, version_id, label, force=0):
def createBranch(self, branch_id, version_id):
"""Create a new branch associated with the given branch_id. The
new branch is rooted at the version named by version_id."""
if self._branches.has_key(branch_id):
if branch_id in self._branches:
raise VersionControlError(
'Activity already exists: %s' % branch_id
)
Expand Down Expand Up @@ -134,7 +134,7 @@ def createVersion(self, object, branch_id):
security.declarePrivate('hasVersionId')
def hasVersionId(self, version_id):
"""Return true if history contains a version with the given id."""
return self._versions.has_key(version_id)
return version_id in self._versions

security.declarePrivate('isLatestVersion')
def isLatestVersion(self, version_id, branch_id):
Expand Down

0 comments on commit 854d105

Please sign in to comment.