From ed53ecda0546d6c639fa3d227a59ace4d57b81a5 Mon Sep 17 00:00:00 2001 From: Upasana Date: Mon, 5 Mar 2018 00:58:41 +0100 Subject: Bug 1273381 - Improve bugzilla object performance by using Class::XSAccessor for object accessors --- Bugzilla/Bug.pm | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'Bugzilla/Bug.pm') diff --git a/Bugzilla/Bug.pm b/Bugzilla/Bug.pm index ee48ed7a2..5e45b67b1 100644 --- a/Bugzilla/Bug.pm +++ b/Bugzilla/Bug.pm @@ -54,7 +54,15 @@ my %CLEANUP; use constant DB_TABLE => 'bugs'; use constant ID_FIELD => 'bug_id'; + use constant NAME_FIELD => 'alias'; +use Class::XSAccessor { + accessors => { + id => __PACKAGE__->ID_FIELD, + name => __PACKAGE__->NAME_FIELD, + }, +}; + use constant LIST_ORDER => ID_FIELD; # Bugs have their own auditing table, bugs_activity. use constant AUDIT_CREATES => 0; -- cgit v1.2.3-24-g4f1b