Closed Bug 539865 Opened 15 years ago Closed 15 years ago

Bugzilla::Object should pass $params to validators during create() (implement VALIDATOR_DEPENDENCIES)

Categories

(Bugzilla :: Bugzilla-General, enhancement)

3.5.2
enhancement
Not set
normal

Tracking

()

RESOLVED FIXED
Bugzilla 4.0

People

(Reporter: mkanat, Assigned: mkanat)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

Right now we have a lot of special validators in run_create_validators for a lot of objects. Almost all of our run_create_validators code could be eliminated if we just always passed $params to each validator during create(), and could specify an order that validators were to be called in during create().
Keywords: relnote
Target Milestone: --- → Bugzilla 3.8
Summary: Bugzilla::Object should pass $params to validators during create() → Bugzilla::Object should pass $params to validators during create() (implement VALIDATOR_DEPENDENCIES)
Attached patch v1Splinter Review
Okay, this should pretty much let us get rid of UPDATE_VALIDATORS/run_create_validators and also give us a nice way to make set_all run all the "setters" for every object in the right order without having to remember what order they're all supposed to go in.
Assignee: general → mkanat
Status: NEW → ASSIGNED
Attachment #436664 - Flags: review?(LpSolit)
Blocks: 556731
Comment on attachment 436664 [details] [diff] [review] v1 r=LpSolit
Attachment #436664 - Flags: review?(LpSolit) → review+
Flags: approval+
Committing to: bzr+ssh://bzr.mozilla.org/bugzilla/trunk/ modified email_in.pl modified post_bug.cgi modified Bugzilla/Comment.pm modified Bugzilla/Object.pm modified extensions/Example/Extension.pm Committed revision 7140.
Status: ASSIGNED → RESOLVED
Closed: 15 years ago
Resolution: --- → FIXED
Added to the release notes in bug 604256.
Keywords: relnote
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: