Project

General

Profile

Actions

Bug #12888

closed

exception handling during api call causes does not handle 'class' errors

Added by Justin Sherrill over 8 years ago. Updated almost 6 years ago.

Status:
Closed
Priority:
Normal
Category:
API
Target version:
Difficulty:
trivial
Triaged:
Yes
Fixed in Releases:
Found in Releases:

Description

When testing a pr i noticed that if something like scoped search throws an error, you get anothe rexception.

To reproduce:

In app/models/product.rb, add:

scoped_search :on => :foo

and then search for products with "foo = bar":

http://devbox:3000/katello/api/v2/products?organization_id=1&search=foo=bar

Result:

undefined method `errors' for #<Class:0x00000007244490>

Actions #1

Updated by The Foreman Bot over 8 years ago

  • Status changed from New to Ready For Testing
  • Pull request https://github.com/Katello/katello/pull/5673 added
Actions #2

Updated by The Foreman Bot over 8 years ago

  • Pull request https://github.com/Katello/katello/pull/5675 added
Actions #3

Updated by Justin Sherrill over 8 years ago

  • Pull request deleted (https://github.com/Katello/katello/pull/5675)
Actions #4

Updated by Justin Sherrill over 8 years ago

  • Status changed from Ready For Testing to Closed
  • % Done changed from 0 to 100
Actions

Also available in: Atom PDF