diff --git a/lib/WebGUI/Account.pm b/lib/WebGUI/Account.pm index 05d65308b..924c8382c 100644 --- a/lib/WebGUI/Account.pm +++ b/lib/WebGUI/Account.pm @@ -3,6 +3,7 @@ package WebGUI::Account; use strict; use Moose; +use WebGUI::BestPractices; has session => ( is => 'ro', diff --git a/lib/WebGUI/BestPractices.pm b/lib/WebGUI/BestPractices.pm new file mode 100644 index 000000000..424290c2d --- /dev/null +++ b/lib/WebGUI/BestPractices.pm @@ -0,0 +1,43 @@ +package WebGUI::BestPractices; + +=head1 LEGAL + + ------------------------------------------------------------------- + WebGUI is Copyright 2001-2009 Plain Black Corporation. + ------------------------------------------------------------------- + Please read the legal notices (docs/legal.txt) and the license + (docs/license.txt) that came with this distribution before using + this software. + ------------------------------------------------------------------- + http://www.plainblack.com info@plainblack.com + ------------------------------------------------------------------- + +=head1 NAME + +WebGUI::BestPractices - Enable WebGUI best practice pragmas + +=head1 SYNOPSIS + + use WebGUI::BestPractices; + +=head1 DESCRIPTION + +This module is the equivalent of adding the following to your module: + + use strict; + use warnings; + no warnings 'uninitialized'; + use feature; + use namespace::autoclean; + +=cut + +sub import { + strict->import; + warnings->import; + warnings->unimport('uninitialized'); + feature->import(':5.10'); + namespace::autoclean->import; +} + +1;