[CMF-checkins] CVS: CMF/CMFStaging - VersionsTool.py:1.13
Grégoire Weber
zope.org at incept.ch
Mon Jan 19 15:54:54 EST 2004
Update of /cvs-repository/CMF/CMFStaging
In directory cvs.zope.org:/tmp/cvs-serv25395
Modified Files:
VersionsTool.py
Log Message:
On the initial checkin the message gets saved to the repository instead of the 'Initial checkin.' message. If no message is passed the old behaviour is retained.
=== CMF/CMFStaging/VersionsTool.py 1.12 => 1.13 ===
--- CMF/CMFStaging/VersionsTool.py:1.12 Mon Oct 27 15:21:53 2003
+++ CMF/CMFStaging/VersionsTool.py Mon Jan 19 15:54:53 2004
@@ -152,14 +152,14 @@
security.declarePublic('checkin')
- def checkin(self, obj, message=''):
+ def checkin(self, obj, message=None):
"""Checks in a new version.
"""
verifyPermission(UseVersionControl, obj)
obj = unproxied(obj)
repo = self._getVersionRepository()
if not repo.isUnderVersionControl(obj):
- repo.applyVersionControl(obj)
+ repo.applyVersionControl(obj, message)
else:
if (not repo.isResourceUpToDate(obj, require_branch=1)
and self.isCheckedOut(obj)):
@@ -181,7 +181,7 @@
for key, value in new_dict.items():
if key != '__vc_info__':
obj.__dict__[key] = value
- repo.checkinResource(obj, message)
+ repo.checkinResource(obj, message or '')
return None
More information about the CMF-checkins
mailing list