匿名用户不可在个人主页留言
This commit is contained in:
parent
e4e99df113
commit
d790fb31e4
|
@ -4,7 +4,7 @@ class WordsController < ApplicationController
|
|||
include ApplicationHelper
|
||||
before_filter :find_user, :only => [:new, :create, :destroy, :more, :back]
|
||||
def create
|
||||
if params[:new_form][:user_message].size>0
|
||||
if params[:new_form][:user_message].size>0 && User.current.logged?
|
||||
unless params[:user_id].nil?
|
||||
if params[:reference_content]
|
||||
message = params[:new_form][:user_message] + "\n" + params[:reference_content]
|
||||
|
@ -31,9 +31,7 @@ class WordsController < ApplicationController
|
|||
# @jour = paginateHelper @jours,10
|
||||
|
||||
respond_to do |format|
|
||||
# format.html { redirect_to_referer_or {render :text => 'Watcher added.', :layout => true}}
|
||||
format.js
|
||||
#format.api { render_api_ok }
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue