Bugzilla – Attachment 153510 Details for
Bug 33745
Speed up Koha::Object attribute accessors
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 33745: (follow-up) Fool perlcritic
Bug-33745-follow-up-Fool-perlcritic.patch (text/plain), 1.02 KB, created by
Marcel de Rooy
on 2023-07-15 17:14:21 UTC
(
hide
)
Description:
Bug 33745: (follow-up) Fool perlcritic
Filename:
MIME Type:
Creator:
Marcel de Rooy
Created:
2023-07-15 17:14:21 UTC
Size:
1.02 KB
patch
obsolete
>From 78f06b277659033e0ddde5119755298c6e6e8a65 Mon Sep 17 00:00:00 2001 >From: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Date: Sat, 15 Jul 2023 17:09:56 +0000 >Subject: [PATCH] Bug 33745: (follow-up) Fool perlcritic >Content-Type: text/plain; charset=utf-8 > >If you work with hashes, everything should be fine :) > >Test plan: >Run qa tools or perlcritic Koha/Object.pm >Prove t/db_dependent/Koha > >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >--- > Koha/Object.pm | 5 +++-- > 1 file changed, 3 insertions(+), 2 deletions(-) > >diff --git a/Koha/Object.pm b/Koha/Object.pm >index 190b57cde9..f97d9cc9c9 100644 >--- a/Koha/Object.pm >+++ b/Koha/Object.pm >@@ -918,8 +918,9 @@ sub AUTOLOAD { > return $self->_result()->get_column($method); > } > }; >- no strict 'refs'; >- *{$AUTOLOAD} = $accessor; >+ # No need for disabling strict if we do it like this: >+ my $symbols = \%main::; >+ $symbols->{__PACKAGE__}{$method} = $accessor; > return $accessor->( $self, @_ ); > } > >-- >2.30.2
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 33745
:
151273
|
151274
|
151275
|
151290
|
153449
|
153450
|
153451
|
153452
|
153510
|
153525
|
153584
|
153586