app/controllers/room_messages_controller.rb
# If message is empty then prevent to send
If message is empty then prevent to send
If message is empty then prevent to send
def check_empty_message
    if params[:room_message][:message].empty?
      redirect_to room_path(@conversation)
    end
  end
def check_empty_message if params [ :room_message ] [ :message ] . empty? redirect_to room_path ( @conversation ) end end
If message is empty then prevent to send
If message is empty then prevent to send