changeset 1609:7f73dafb525d

move attachments: remove unneeded imports
author Thomas Waldmann <tw AT waldmann-edv DOT de>
date Sun, 08 Oct 2006 21:02:03 +0200
parents 7a26b4c769f3
children 48194fc011e5
files MoinMoin/action/AttachFile.py
diffstat 1 files changed, 3 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/MoinMoin/action/AttachFile.py	Sun Oct 08 20:39:38 2006 +0200
+++ b/MoinMoin/action/AttachFile.py	Sun Oct 08 21:02:03 2006 +0200
@@ -682,15 +682,11 @@
 def move_file(request, pagename, new_pagename, attachment, new_attachment):
     _ = request.getText
 
-    from MoinMoin.PageEditor import PageEditor
-    newpage = PageEditor(request, new_pagename)
-
+    newpage = Page(request, new_pagename)
     if newpage.exists(includeDeleted=1) and request.user.may.write(new_pagename) and request.user.may.delete(pagename):
-        from MoinMoin.util import filesys
-        from MoinMoin.action import AttachFile
-        new_attachment_path = os.path.join(AttachFile.getAttachDir(request, new_pagename,
+        new_attachment_path = os.path.join(getAttachDir(request, new_pagename,
                               create=1), new_attachment).encode(config.charset)
-        attachment_path = os.path.join(AttachFile.getAttachDir(request, pagename),
+        attachment_path = os.path.join(getAttachDir(request, pagename),
                           attachment).encode(config.charset)
 
         if os.path.exists(new_attachment_path):