[Zope3-checkins] CVS: Zope3/src/zope/app/browser/content - fssync.py:1.14

Guido van Rossum guido@python.org
Wed, 28 May 2003 15:58:51 -0400


Update of /cvs-repository/Zope3/src/zope/app/browser/content
In directory cvs.zope.org:/tmp/cvs-serv18028

Modified Files:
	fssync.py 
Log Message:
When committing to the root, append "root" to the fspath.


=== Zope3/src/zope/app/browser/content/fssync.py 1.13 => 1.14 ===
--- Zope3/src/zope/app/browser/content/fssync.py:1.13	Tue May 27 15:46:51 2003
+++ Zope3/src/zope/app/browser/content/fssync.py	Wed May 28 15:58:50 2003
@@ -97,9 +97,12 @@
             if container is None and name == "":
                 # Hack to get loading the root to work
                 container = getRoot(self.context)
+                fspath = os.path.join(working, "root")
+            else:
+                fspath = os.path.join(working, name)
             md = Metadata()
             c = Committer(md)
-            c.synch(container, name, os.path.join(working, name))
+            c.synch(container, name, fspath)
             # 4) Generate response (snarfed archive or error text)
             errors = c.get_errors()
             if not errors: