Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Remove the IRC bot stuff, since we are not going to use it.

  • Loading branch information...
commit 36c80fad40a7133a63e595cb3a4b6560897d1785 1 parent 503061c
@relrod authored
View
31 app/controllers/application_controller.rb
@@ -1,34 +1,3 @@
class ApplicationController < ActionController::Base
protect_from_forgery
-
- private
- def connect_irc
- return if $socket
- require 'socket'
- $socket = TCPSocket.new 'localhost', 6667
- $socket.puts "NICK acm-qdb"
- $socket.puts "USER acm-qdb * * :The Univ. of Akron Student ACM Chapter QDB"
-
- Thread.new do
- while line = $socket.gets.strip
- puts line
- if line =~ /^PING/
- $socket.puts line.sub('I', 'O')
- elsif line.split[1] == '376'
- $socket.puts "JOIN #uakroncs"
- elsif line =~ /:!inspect (\d+)/
- quote = Quote.find_by_id($1)
- if not quote.nil?
- log quote.inspect
- end
- end
- end
- end
-
- end
-
- def log(message, channel="#uakroncs")
- connect_irc
- $socket.puts "PRIVMSG #{channel} :#{message}"
- end
end
View
1  app/controllers/quotes_controller.rb
@@ -47,7 +47,6 @@ def create
respond_to do |format|
if @quote.save
- #log "Quote created: #{@quote.id}"
format.html { redirect_to(@quote, :notice => 'Quote was successfully created.') }
format.xml { render :xml => @quote, :status => :created, :location => @quote }
else
Please sign in to comment.
Something went wrong with that request. Please try again.