Commit 3cd60d962a2bf46ed4729674d9015c0a4a66e6ae
Committed by
Paulo Meireles
1 parent
a865a6e9
Exists in
master
and in
29 other branches
[Mezuro] Fixed exceptions handling in controller
Showing
2 changed files
with
2 additions
and
2 deletions
Show diff stats
plugins/mezuro/controllers/mezuro_plugin_myprofile_controller.rb
@@ -148,7 +148,7 @@ class MezuroPluginMyprofileController < ProfileController | @@ -148,7 +148,7 @@ class MezuroPluginMyprofileController < ProfileController | ||
148 | end | 148 | end |
149 | 149 | ||
150 | def look_for_configuration_content_errors | 150 | def look_for_configuration_content_errors |
151 | - redirect_to_error_page(@configuration_content.errors[:base]) if not @configuration_content.errors.nil? | 151 | + redirect_to_error_page(@configuration_content.errors[:base]) if not @configuration_content.errors[:base].nil? |
152 | end | 152 | end |
153 | 153 | ||
154 | def look_for_model_error(model) | 154 | def look_for_model_error(model) |
plugins/mezuro/controllers/mezuro_plugin_profile_controller.rb
@@ -105,7 +105,7 @@ class MezuroPluginProfileController < ProfileController | @@ -105,7 +105,7 @@ class MezuroPluginProfileController < ProfileController | ||
105 | end | 105 | end |
106 | 106 | ||
107 | def project_content_errors? | 107 | def project_content_errors? |
108 | - not @content.errors.nil? | 108 | + not @content.errors[:base].nil? |
109 | end | 109 | end |
110 | end | 110 | end |
111 | 111 |