summaryrefslogtreecommitdiffstats
path: root/extensions
diff options
context:
space:
mode:
Diffstat (limited to 'extensions')
-rw-r--r--extensions/BugmailFilter/lib/Filter.pm6
-rw-r--r--extensions/MyDashboard/lib/BugInterest.pm8
-rw-r--r--extensions/Push/lib/BacklogMessage.pm7
-rw-r--r--extensions/Push/lib/Backoff.pm7
-rw-r--r--extensions/Push/lib/LogEntry.pm7
-rw-r--r--extensions/Push/lib/Message.pm6
-rw-r--r--extensions/Push/lib/Option.pm9
-rw-r--r--extensions/Review/lib/FlagStateActivity.pm10
-rw-r--r--extensions/TrackingFlags/lib/Flag.pm11
-rw-r--r--extensions/TrackingFlags/lib/Flag/Bug.pm7
-rw-r--r--extensions/TrackingFlags/lib/Flag/Value.pm9
-rw-r--r--extensions/TrackingFlags/lib/Flag/Visibility.pm7
12 files changed, 6 insertions, 88 deletions
diff --git a/extensions/BugmailFilter/lib/Filter.pm b/extensions/BugmailFilter/lib/Filter.pm
index e7e339cd4..7f2f4cb87 100644
--- a/extensions/BugmailFilter/lib/Filter.pm
+++ b/extensions/BugmailFilter/lib/Filter.pm
@@ -54,12 +54,6 @@ use constant AUDIT_REMOVES => 0;
use constant USE_MEMCACHED => 0;
# getters
-use Class::XSAccessor {
- accessors => {
- id => __PACKAGE__->ID_FIELD,
- name => __PACKAGE__->NAME_FIELD,
- },
-};
sub user {
my ($self) = @_;
diff --git a/extensions/MyDashboard/lib/BugInterest.pm b/extensions/MyDashboard/lib/BugInterest.pm
index 2e8655261..cf33900c5 100644
--- a/extensions/MyDashboard/lib/BugInterest.pm
+++ b/extensions/MyDashboard/lib/BugInterest.pm
@@ -34,13 +34,7 @@ use constant { AUDIT_CREATES => 0,
# Provide accessors for our columns
#####################################################################
-use Class::XSAccessor {
- accessors => {
- id => __PACKAGE__->ID_FIELD,
- name => __PACKAGE__->NAME_FIELD,
- },
-};
-
+sub id { return $_[0]->{id} }
sub bug_id { return $_[0]->{bug_id} }
sub user_id { return $_[0]->{user_id} }
sub modification_time { return $_[0]->{modification_time} }
diff --git a/extensions/Push/lib/BacklogMessage.pm b/extensions/Push/lib/BacklogMessage.pm
index 7c248a501..28b17bae3 100644
--- a/extensions/Push/lib/BacklogMessage.pm
+++ b/extensions/Push/lib/BacklogMessage.pm
@@ -79,13 +79,6 @@ sub create_from_message {
# accessors
#
-use Class::XSAccessor {
- accessors => {
- id => __PACKAGE__->ID_FIELD,
- name => __PACKAGE__->NAME_FIELD,
- },
-};
-
sub message_id { return $_[0]->{'message_id'} }
sub push_ts { return $_[0]->{'push_ts'}; }
sub payload { return $_[0]->{'payload'}; }
diff --git a/extensions/Push/lib/Backoff.pm b/extensions/Push/lib/Backoff.pm
index d0de1310d..f0116a2a7 100644
--- a/extensions/Push/lib/Backoff.pm
+++ b/extensions/Push/lib/Backoff.pm
@@ -47,13 +47,6 @@ use constant LIST_ORDER => 'next_attempt_ts';
# accessors
#
-use Class::XSAccessor {
- accessors => {
- id => __PACKAGE__->ID_FIELD,
- name => __PACKAGE__->NAME_FIELD,
- },
-};
-
sub connector { return $_[0]->{'connector'}; }
sub next_attempt_ts { return $_[0]->{'next_attempt_ts'}; }
sub attempts { return $_[0]->{'attempts'}; }
diff --git a/extensions/Push/lib/LogEntry.pm b/extensions/Push/lib/LogEntry.pm
index 2d45b9ee1..f4e894b94 100644
--- a/extensions/Push/lib/LogEntry.pm
+++ b/extensions/Push/lib/LogEntry.pm
@@ -48,13 +48,6 @@ use constant LIST_ORDER => 'processed_ts DESC';
# accessors
#
-use Class::XSAccessor {
- accessors => {
- id => __PACKAGE__->ID_FIELD,
- name => __PACKAGE__->NAME_FIELD,
- },
-};
-
sub message_id { return $_[0]->{'message_id'}; }
sub change_set { return $_[0]->{'change_set'}; }
sub routing_key { return $_[0]->{'routing_key'}; }
diff --git a/extensions/Push/lib/Message.pm b/extensions/Push/lib/Message.pm
index d8a7f7a26..1beb18ef0 100644
--- a/extensions/Push/lib/Message.pm
+++ b/extensions/Push/lib/Message.pm
@@ -61,12 +61,6 @@ sub create_from_transient {
#
# accessors
#
-use Class::XSAccessor {
- accessors => {
- id => __PACKAGE__->ID_FIELD,
- name => __PACKAGE__->NAME_FIELD,
- },
-};
sub push_ts { return $_[0]->{'push_ts'}; }
sub payload { return $_[0]->{'payload'}; }
diff --git a/extensions/Push/lib/Option.pm b/extensions/Push/lib/Option.pm
index c2e23d513..a08e4c11d 100644
--- a/extensions/Push/lib/Option.pm
+++ b/extensions/Push/lib/Option.pm
@@ -35,18 +35,13 @@ use constant VALIDATORS => {
connector => \&_check_connector,
};
use constant LIST_ORDER => 'connector';
-use constant NAME_FIELD => 'option_name';
+
#
# accessors
#
-use Class::XSAccessor {
- accessors => {
- id => __PACKAGE__->ID_FIELD,
- name => __PACKAGE__->NAME_FIELD,
- },
-};
sub connector { return $_[0]->{'connector'}; }
+sub name { return $_[0]->{'option_name'}; }
sub value { return $_[0]->{'option_value'}; }
#
diff --git a/extensions/Review/lib/FlagStateActivity.pm b/extensions/Review/lib/FlagStateActivity.pm
index fcc799a79..35da42351 100644
--- a/extensions/Review/lib/FlagStateActivity.pm
+++ b/extensions/Review/lib/FlagStateActivity.pm
@@ -35,16 +35,6 @@ use constant DB_COLUMNS => qw(
status
);
-###############################
-#### Accessors ######
-###############################
-
-use Class::XSAccessor {
- accessors => {
- id => __PACKAGE__->ID_FIELD,
- name => __PACKAGE__->NAME_FIELD,
- },
-};
sub _check_param_required {
my ($param) = @_;
diff --git a/extensions/TrackingFlags/lib/Flag.pm b/extensions/TrackingFlags/lib/Flag.pm
index f54e42a7a..82c0314e3 100644
--- a/extensions/TrackingFlags/lib/Flag.pm
+++ b/extensions/TrackingFlags/lib/Flag.pm
@@ -376,16 +376,8 @@ sub set_is_active { $_[0]->set('is_active', $_[1]); }
#### Accessors ####
###############################
-use constant ID_FIELD => 'field_id';
-
-use Class::XSAccessor {
- accessors => {
- id => __PACKAGE__->ID_FIELD,
- name => __PACKAGE__->NAME_FIELD,
- },
-};
-
sub flag_id { return $_[0]->{'id'}; }
+sub name { return $_[0]->{'name'}; }
sub description { return $_[0]->{'description'}; }
sub flag_type { return $_[0]->{'type'}; }
sub sortkey { return $_[0]->{'sortkey'}; }
@@ -468,6 +460,7 @@ sub activity_count {
# Here we return 'field_id' instead of the real
# id as we want other Bugzilla code to treat this
# as a Bugzilla::Field object in certain places.
+sub id { return $_[0]->{'field_id'}; }
sub type { return FIELD_TYPE_EXTENSION; }
sub legal_values { return $_[0]->values; }
sub custom { return 1; }
diff --git a/extensions/TrackingFlags/lib/Flag/Bug.pm b/extensions/TrackingFlags/lib/Flag/Bug.pm
index 62f103ee5..7be661720 100644
--- a/extensions/TrackingFlags/lib/Flag/Bug.pm
+++ b/extensions/TrackingFlags/lib/Flag/Bug.pm
@@ -169,13 +169,6 @@ sub set_value { $_[0]->set('value', $_[1]); }
#### Accessors ####
###############################
-use Class::XSAccessor {
- accessors => {
- id => __PACKAGE__->ID_FIELD,
- name => __PACKAGE__->NAME_FIELD,
- },
-};
-
sub tracking_flag_id { return $_[0]->{'tracking_flag_id'}; }
sub bug_id { return $_[0]->{'bug_id'}; }
sub value { return $_[0]->{'value'}; }
diff --git a/extensions/TrackingFlags/lib/Flag/Value.pm b/extensions/TrackingFlags/lib/Flag/Value.pm
index c1b3ef4f1..4f2aacc3a 100644
--- a/extensions/TrackingFlags/lib/Flag/Value.pm
+++ b/extensions/TrackingFlags/lib/Flag/Value.pm
@@ -35,7 +35,6 @@ use constant DB_COLUMNS => qw(
);
use constant LIST_ORDER => 'sortkey';
-use constant NAME_FIELD => 'value';
use constant UPDATE_COLUMNS => qw(
setter_group_id
@@ -112,13 +111,6 @@ sub set_comment { $_[0]->set('comment', $_[1]); }
#### Accessors ####
###############################
-use Class::XSAccessor {
- accessors => {
- id => __PACKAGE__->ID_FIELD,
- name => __PACKAGE__->NAME_FIELD,
- },
-};
-
sub tracking_flag_id { return $_[0]->{'tracking_flag_id'}; }
sub setter_group_id { return $_[0]->{'setter_group_id'}; }
sub value { return $_[0]->{'value'}; }
@@ -148,6 +140,7 @@ sub setter_group {
## Compatibility with Bugzilla::Field ##
########################################
+sub name { return $_[0]->{'value'}; }
sub is_visible_on_bug { return 1; }
1;
diff --git a/extensions/TrackingFlags/lib/Flag/Visibility.pm b/extensions/TrackingFlags/lib/Flag/Visibility.pm
index a16ddfe75..878c16f99 100644
--- a/extensions/TrackingFlags/lib/Flag/Visibility.pm
+++ b/extensions/TrackingFlags/lib/Flag/Visibility.pm
@@ -147,13 +147,6 @@ sub _check_component {
#### Accessors ####
###############################
-use Class::XSAccessor {
- accessors => {
- id => __PACKAGE__->ID_FIELD,
- name => __PACKAGE__->NAME_FIELD,
- },
-};
-
sub tracking_flag_id { return $_[0]->{'tracking_flag_id'}; }
sub product_id { return $_[0]->{'product_id'}; }
sub component_id { return $_[0]->{'component_id'}; }