Making the default_scope call compatible with Rails 4

Calling #default_scope without a block is deprecated in Rails 4.0 and totally
removed in Rails 4.1.
make default_scope call compatible with Rails 4
sqlite3 gem has changed names