[open-ils-commits] r1356 - servres/trunk/conifer/syrup/views (gfawcett)
svn at svn.open-ils.org
svn at svn.open-ils.org
Wed Apr 13 20:51:28 EDT 2011
Author: gfawcett
Date: 2011-04-13 20:51:26 -0400 (Wed, 13 Apr 2011)
New Revision: 1356
Modified:
servres/trunk/conifer/syrup/views/sites.py
Log:
conifer/syrup/views/sites.py: don't freak when undoing paste, if something you want to delete is already gone.
Modified: servres/trunk/conifer/syrup/views/sites.py
===================================================================
--- servres/trunk/conifer/syrup/views/sites.py 2011-04-14 00:51:23 UTC (rev 1355)
+++ servres/trunk/conifer/syrup/views/sites.py 2011-04-14 00:51:26 UTC (rev 1356)
@@ -266,6 +266,9 @@
if request.method != 'POST':
return g.render('site_confirm_paste_undo.xhtml', **locals())
for item_id in item_list:
- site.item_set.get(pk=item_id).delete()
+ try:
+ site.item_set.get(pk=item_id).delete()
+ except:
+ pass
del request.session['last_paste']
return HttpResponseRedirect('../')
More information about the open-ils-commits
mailing list