Mercurial > moin > 1.9
changeset 2000:f77a7f6bb560
info action: don't try to stat attachments that don't exist
author | Johannes Berg <johannes AT sipsolutions DOT net> |
---|---|
date | Tue, 17 Apr 2007 13:01:20 +0200 |
parents | a82f06dba7ca |
children | 8f130438d8e8 |
files | MoinMoin/action/info.py |
diffstat | 1 files changed, 2 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/MoinMoin/action/info.py Tue Apr 17 11:09:33 2007 +0200 +++ b/MoinMoin/action/info.py Tue Apr 17 13:01:20 2007 +0200 @@ -131,7 +131,8 @@ size = 0 if line.action != 'ATTDEL': from MoinMoin.action import AttachFile - size = AttachFile.size(request, pagename, filename) + if AttachFile.exists(request, pagename, filename): + size = AttachFile.size(request, pagename, filename) if line.action == 'ATTNEW': actions.append(render_action(_('view'), {'action': 'AttachFile', 'do': 'view', 'target': '%s' % filename})) elif line.action == 'ATTDRW':