My favorites
▼
|
Sign in
substruct
Open-source Ruby on Rails E-Commerce
Project Home
Downloads
Wiki
Issues
Source
READ-ONLY: This project has been
archived
. For more information see
this post
.
Search
Search within:
All issues
Open issues
New issues
Issues to verify
for
Advanced search
Search tips
Subscriptions
Issue
96
attachment: dont_crash_with_invalid_tag.patch
(811 bytes)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
Index: /home/edmundo/workspace_aptana/trunk/vendor/plugins/substruct/app/controllers/store_controller.rb
===================================================================
--- /home/edmundo/workspace_aptana/trunk/vendor/plugins/substruct/app/controllers/store_controller.rb (revision 78)
+++ /home/edmundo/workspace_aptana/trunk/vendor/plugins/substruct/app/controllers/store_controller.rb (working copy)
@@ -80,7 +80,10 @@
temp_tag = Tag.find_by_name(name)
if temp_tag then
tag_ids_array << temp_tag.id
- end
+ else
+ flash[:notice] = "Sorry, we couldn't find the tag #{name} you were looking for."
+ redirect_to :action => 'index' and return false
+ end
end
@viewing_tags = Tag.find(tag_ids_array)
viewing_tag_names = @viewing_tags.collect { |t| " > #{t.name}"}
Powered by
Google Project Hosting