https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22026
Bug ID: 22026
Summary: Remove `use Modern::Perl` from Koha::REST::classes
Change sponsored?: ---
Product: Koha
Version: master
Hardware: All
OS: All
Status: NEW
Severity: enhancement
Priority: P5 - low
Component: Architecture, internals, and plumbing
Assignee: [email protected]
Reporter: [email protected]
QA Contact: [email protected]
Target Milestone: ---
The REST api is based on Mojolicious and as such the controllers within this
namespace are all based upon `Mojo::Base`, `use Mojo::Base
'Mojolicious::Controller';` to be specific.
Mojo::Base enables the following, which are the only useful things achieved by
Modern::Perl in our case (as we limit ourselves to supporting perl 5.10, so any
and all other features past perl 5.10 are unavailable to use anyway).
```
use strict;
use warnings;
use utf8;
use feature ':5.10';
use mro;
use IO::Handle ();
require SomeBaseClass;
push @ISA, 'SomeBaseClass';
sub has { Mojo::Base::attr(__PACKAGE__, @_) }
```
As such, adding the `use Modern::Perl` statement is just noise and needlessly
loads a module.
--
You are receiving this mail because:
You are watching all bug changes.
You are the assignee for the bug.
_______________________________________________
Koha-bugs mailing list
[email protected]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/