Eddie Fisher
Eddie Fisher
``` irb(main):021:0> HostSearch.search(ip: '192') NameError: uninitialized constant SearchCopGrammar::Attributes::Inet from /Users/user/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/search_cop-1.0.6/lib/search_cop_grammar/attributes.rb:89:in `const_get' from /Users/user/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/search_cop-1.0.6/lib/search_cop_grammar/attributes.rb:89:in `attribute_for' from /Users/user/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/search_cop-1.0.6/lib/search_cop_grammar/attributes.rb:55:in `block in attributes' from /Users/user/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/search_cop-1.0.6/lib/search_cop_grammar/attributes.rb:55:in `collect' from /Users/user/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/search_cop-1.0.6/lib/search_cop_grammar/attributes.rb:55:in `attributes' from /Users/user/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/search_cop-1.0.6/lib/search_cop_grammar/attributes.rb:38:in `matches' from /Users/user/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/search_cop-1.0.6/lib/search_cop/hash_parser.rb:38:in...
db: posgresql
``` class HostSearch < ::Host include SearchCop search_scope :search do attributes :ip, :name end end ```
schema ``` create_table "hosts", force: :cascade do |t| t.inet "ip", null: false t.string "name", limit: 255 end ```