Closed
Bug 204104
Opened 22 years ago
Closed 22 years ago
internal error in Search.pm when searching for invalid keyword or an email with no email type specified
Categories
(Bugzilla :: Query/Bug List, defect)
Tracking
()
RESOLVED
FIXED
Bugzilla 2.18
People
(Reporter: morgamic, Assigned: morgamic)
Details
Attachments
(1 file, 2 obsolete files)
2.01 KB,
patch
|
bbaetz
:
review+
|
Details | Diff | Splinter Review |
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.3) Gecko/20030312
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.3) Gecko/20030312
if you search for an invalid keyword, ThrowUserError is undefined in Search.pm
because it is missing a &::.
also, while fixing this, i stumbled on a similar error found for the
ThrowUserError for a missing_email_type (message: You must specify one or more
fields in which to search for <tt>[% email FILTER html %]</tt>.)
if you add the &:: to both lines, everything works fine. this is relative to
bug 178801, a resolved, similar issue with other ThrowUserError calls in Search.pm.
Reproducible: Always
Steps to Reproduce:
1. query.cgi
2. put in a non-existing keyword (foofooasdfasdf) OR search for an email without
selecting a type to search for
3. conduct search
Actual Results:
internal server error (500)
Expected Results:
it should display a user error message (red box) with the appropriate error
string as defined in /template/en/default/global/user-error.html.tmpl
Assignee | ||
Comment 1•22 years ago
|
||
Assignee | ||
Comment 2•22 years ago
|
||
Attachment #122226 -
Attachment is obsolete: true
Assignee | ||
Updated•22 years ago
|
Attachment #122227 -
Flags: review+
Assignee | ||
Updated•22 years ago
|
Attachment #122227 -
Flags: review+ → review?(justdave)
Comment 3•22 years ago
|
||
Comment on attachment 122227 [details] [diff] [review]
patch v2: obvious fix in the obvious fix
No, the correct fix is to |use Bugzilla::Exception;| at the top of the file -
this happened when I moved stuff arround earlier, but forgot the |use|.
I knew about this bug, but I thought I'd already fixed it. It obviously slipped
through the cracks, though
Attachment #122227 -
Flags: review?(justdave) → review-
Assignee | ||
Comment 4•22 years ago
|
||
ok. after some futher discussion with Bradley, it became apparent that adding
the &:: is pointless if we are going to be moving towards using
Bugzilla::Error.
so, let's revamp our approach. here is a patch that:
a) includes the |use Bugzilla::Error;| (not Exception)
b) subsequently removes all &::'s from calls to ThrowUserError
hopefully that will be a better remedy, and, considering the work Bradley is
doing elsewhere, a step in the right direction.
Attachment #122227 -
Attachment is obsolete: true
Assignee | ||
Updated•22 years ago
|
Attachment #122230 -
Flags: review?(bbaetz)
Comment 5•22 years ago
|
||
Comment on attachment 122230 [details] [diff] [review]
patch v3: use Bugzilla::Error, remove &::'s
This looks fine. r=bbaetz
Attachment #122230 -
Flags: review?(bbaetz) → review+
Comment 6•22 years ago
|
||
-> patcher
Assignee: endico → mike.morgan
Status: UNCONFIRMED → NEW
Ever confirmed: true
Target Milestone: --- → Bugzilla 2.18
Updated•22 years ago
|
Flags: approval?
Updated•22 years ago
|
Flags: approval? → approval+
Comment 7•22 years ago
|
||
Fixed.
Checking in Bugzilla/Search.pm;
/cvsroot/mozilla/webtools/bugzilla/Bugzilla/Search.pm,v <-- Search.pm
new revision: 1.40; previous revision: 1.39
done
Status: NEW → RESOLVED
Closed: 22 years ago
Resolution: --- → FIXED
Updated•12 years ago
|
QA Contact: matty_is_a_geek → default-qa
You need to log in
before you can comment on or make changes to this bug.
Description
•