[galaxy-commits] galaxy-dist commit 4f157f2c6fd9: Bug fix for history/view when history has no user.
commits-noreply at bitbucket.org
commits-noreply at bitbucket.org
Fri Jul 16 10:06:34 EDT 2010
# HG changeset patch -- Bitbucket.org
# Project galaxy-dist
# URL http://bitbucket.org/galaxy/galaxy-dist/overview
# User Dan Blankenberg <dan at bx.psu.edu>
# Date 1279204138 14400
# Node ID 4f157f2c6fd9cc1b692e55fe38dd66243e881439
# Parent 9638200fbfdcc470675ca6b65f0220f28ed1809c
Bug fix for history/view when history has no user.
--- a/templates/history/view.mako
+++ b/templates/history/view.mako
@@ -68,8 +68,10 @@
<%
##TODO: is there a better way to create this URL? Can't use 'f-username' as a key b/c it's not a valid identifier.
href_to_published_histories = h.url_for( controller='/history', action='list_published')
- href_to_user_histories = h.url_for( controller='/history', action='list_published', xxx=history.user.username)
- href_to_user_histories = href_to_user_histories.replace( 'xxx', 'f-username')
+ if history.user is not None:
+ href_to_user_histories = h.url_for( controller='/history', action='list_published', xxx=history.user.username).replace( 'xxx', 'f-username')
+ else:
+ href_to_user_histories = h.url_for( controller='/history', action='list_published' )##should this instead be be None or empty string?
%><div class="unified-panel-header" unselectable="on">
More information about the galaxy-commits
mailing list