changeset 31:b9bc86ad2445

arnica_slides: removed various definitions of msg = None parameter
author Reimar Bauer <rb.proj AT googlemail DOT com>
date Sat, 24 May 2008 10:23:35 +0200
parents f28165322ad3
children 03db81d282ce
files data/plugin/action/arnica_slides.py
diffstat 1 files changed, 3 insertions(+), 9 deletions(-) [+]
line wrap: on
line diff
--- a/data/plugin/action/arnica_slides.py	Sat May 24 10:05:13 2008 +0200
+++ b/data/plugin/action/arnica_slides.py	Sat May 24 10:23:35 2008 +0200
@@ -408,10 +408,8 @@
             request.write(html)
             request.write(request.formatter.endContent())
             request.write(request.theme.send_footer(pagename))
-            msg = None
 
         elif command == 'view':
-            msg = None
             if not request.user.may.read(pagename):
                 msg = _('You are not allowed to view attachments of this page.')
 
@@ -442,20 +440,18 @@
                     'Content-Disposition: %s; filename="%s"' % (content_dispo, filename_enc),
                      ])
 
-                    # send data
+                # send data
                 request.send_file(open(fpath, 'rb'))
 
         elif command == 'PS':
-            msg = None
+            pass
 
         elif command == 'BS':
-            msg = "gone back"
+            pass
 
         elif request.user.may.delete(pagename) and request.request_method == 'POST':
         # only users which are allowed to delete should use this tool
         # ToDo besides lots of refactoring, logig when what is needed has to be rechecked
-
-            target = request.form.get('target', [''])[0]
             filename, ext = os.path.splitext(target)
 
             if ext == '.gif'  or  ext == '.png':
@@ -473,8 +469,6 @@
             cache_thumb = caching.CacheEntry(request, page, thumbfile, scope='item', use_pickle=True)
 
             infile = os.path.join(attachment_path, target)
-
-            msg = None
             # removes (moves to bak)
             if command == 'RM':
                 if os.path.exists(infile + '.bak'):