Commit 2585996c72e56c0b4af05830fc7a5130b72a82f7
1 parent
54701737
Exists in
staging
and in
42 other branches
ActionItem114: minor changes
git-svn-id: https://svn.colivre.coop.br/svn/noosfero/trunk@827 3f533792-8f58-4932-b0fe-aaf55b0a4547
Showing
2 changed files
with
2 additions
and
2 deletions
Show diff stats
app/controllers/application.rb
| ... | ... | @@ -40,7 +40,7 @@ class ApplicationController < ActionController::Base |
| 40 | 40 | def load_profile |
| 41 | 41 | @profile ||= Profile.find_by_identifier(params[:profile]) |
| 42 | 42 | # @profile ||= Profile.find(:first) |
| 43 | - render_not_found(request.path) unless @profile | |
| 43 | + render_not_found(request.path) unless profile | |
| 44 | 44 | end |
| 45 | 45 | |
| 46 | 46 | def render_not_found(path) | ... | ... |
app/controllers/public/category_controller.rb
| ... | ... | @@ -17,7 +17,7 @@ class CategoryController < ApplicationController |
| 17 | 17 | path = params[:path].join('/') |
| 18 | 18 | @category = environment.categories.find_by_path(path) |
| 19 | 19 | if @category.nil? |
| 20 | - render :text => ('No such category (%s).' % path), :status => 404 | |
| 20 | + render_not_found(path) | |
| 21 | 21 | end |
| 22 | 22 | end |
| 23 | 23 | ... | ... |