redirect to the start page if there's no referer in photos#show
This commit is contained in:
parent
b4b3fd2bb3
commit
54feaca998
1 changed files with 5 additions and 1 deletions
|
|
@ -164,7 +164,11 @@ class PhotosController < ApplicationController
|
|||
|
||||
respond_with @photo
|
||||
else
|
||||
redirect_to :back
|
||||
begin
|
||||
redirect_to :back
|
||||
rescue
|
||||
redirect_to aspects_path
|
||||
end
|
||||
end
|
||||
|
||||
end
|
||||
|
|
|
|||
Loading…
Reference in a new issue