SUZUKI Miho
null+****@clear*****
Thu Sep 13 19:17:31 JST 2012
SUZUKI Miho 2012-09-13 19:17:31 +0900 (Thu, 13 Sep 2012) New Revision: 180ad447941d615e0d5b3680892d46bbff6ce1bb https://github.com/logaling/logaling-server/commit/180ad447941d615e0d5b3680892d46bbff6ce1bb Log: Add message if error raised by logaling-command Modified files: app/controllers/user_glossaries_controller.rb Modified: app/controllers/user_glossaries_controller.rb (+1 -0) =================================================================== --- app/controllers/user_glossaries_controller.rb 2012-09-13 18:08:43 +0900 (2762b79) +++ app/controllers/user_glossaries_controller.rb 2012-09-13 19:17:31 +0900 (44cf28c) @@ -31,6 +31,7 @@ class UserGlossariesController < ApplicationController end rescue => e respond_to do |format| + @user_glossary.errors.add(:name, e) if @user_glossary.errors.empty? format.html { render action: "new" } format.json { render json: @user_glossary.errors, status: :unprocessable_entity } end -------------- next part -------------- An HTML attachment was scrubbed... 下載