Skip to content

Commit bf6d104

Browse files
committed
precious tidy
1 parent 0117c9a commit bf6d104

21 files changed

+30
-50
lines changed

lib/MetaCPAN/API.pm

-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ use Mojo::Base 'Mojolicious';
2222
use File::Temp ();
2323
use List::Util qw( any );
2424
use MetaCPAN::Script::Runner ();
25-
use Search::Elasticsearch ();
2625
use Try::Tiny qw( catch try );
2726
use MetaCPAN::Server::Config ();
2827
use MetaCPAN::Types::TypeTiny qw( ES );

lib/MetaCPAN/Document/Author.pm

+3-4
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,9 @@ use ElasticSearchX::Model::Document::Types qw( Location );
77
use ElasticSearchX::Model::Document;
88

99
# load order not important
10-
use Gravatar::URL ();
11-
use MetaCPAN::Document::Author::Profile ();
12-
use MetaCPAN::Types qw( ESBool Profile );
13-
use MetaCPAN::Types::TypeTiny qw(
10+
use Gravatar::URL ();
11+
use MetaCPAN::Types qw( ESBool Profile );
12+
use MetaCPAN::Types::TypeTiny qw(
1413
ArrayRef
1514
ArrayRefPromote
1615
Blog

lib/MetaCPAN/Document/File.pm

+5-13
Original file line numberDiff line numberDiff line change
@@ -10,19 +10,11 @@ use ElasticSearchX::Model::Document;
1010
use List::Util qw( any );
1111
use MetaCPAN::Document::Module ();
1212
use MetaCPAN::Types qw( ESBool Module );
13-
use MetaCPAN::Types::TypeTiny qw(
14-
ArrayRef
15-
Int
16-
Maybe
17-
Num
18-
ScalarRef
19-
Stat
20-
Str
21-
);
22-
use MetaCPAN::Util qw(numify_version true false);
23-
use Plack::MIME ();
24-
use Pod::Text ();
25-
use Try::Tiny qw( catch try );
13+
use MetaCPAN::Types::TypeTiny qw( ArrayRef Int Maybe Num ScalarRef Stat Str );
14+
use MetaCPAN::Util qw(numify_version true false);
15+
use Plack::MIME ();
16+
use Pod::Text ();
17+
use Try::Tiny qw( catch try );
2618

2719
Plack::MIME->add_type( '.t' => 'text/x-script.perl' );
2820
Plack::MIME->add_type( '.pod' => 'text/x-pod' );

lib/MetaCPAN/Document/Release.pm

+2-3
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,8 @@ package MetaCPAN::Document::Release;
33
use Moose;
44

55
use ElasticSearchX::Model::Document;
6-
use MetaCPAN::Document::Dependency ();
7-
use MetaCPAN::Types qw( ESBool Dependency );
8-
use MetaCPAN::Types::TypeTiny qw(
6+
use MetaCPAN::Types qw( Dependency ESBool );
7+
use MetaCPAN::Types::TypeTiny qw(
98
ArrayRef
109
HashRefCPANMeta
1110
Num

lib/MetaCPAN/Model.pm

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Moose;
55

66
use ElasticSearchX::Model;
77
use MetaCPAN::ESConfig qw(es_config);
8-
use Module::Runtime qw(require_module use_package_optimistically);
8+
use Module::Runtime qw( require_module use_package_optimistically );
99

1010
my %indexes;
1111
my $docs = es_config->documents;

lib/MetaCPAN/Model/User/Account.pm

+3-4
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,9 @@ use warnings;
66
use Moose;
77
use ElasticSearchX::Model::Document;
88

9-
use MetaCPAN::Model::User::Identity ();
10-
use MetaCPAN::Types qw( ESBool Identity );
11-
use MetaCPAN::Types::TypeTiny qw( ArrayRef Dict Str );
12-
use MetaCPAN::Util qw(true false);
9+
use MetaCPAN::Types qw( Identity );
10+
use MetaCPAN::Types::TypeTiny qw( ArrayRef Dict Str );
11+
use MetaCPAN::Util qw(true false);
1312

1413
=head1 PROPERTIES
1514

lib/MetaCPAN/Query/Search.pm

+6-7
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,12 @@ package MetaCPAN::Query::Search;
22

33
use MetaCPAN::Moose;
44

5-
use Const::Fast qw( const );
6-
use Hash::Merge qw( merge );
7-
use List::Util qw( min uniq );
8-
use Log::Contextual qw( :log :dlog );
9-
use MetaCPAN::ESConfig qw( es_doc_path );
10-
use MetaCPAN::Types::TypeTiny qw( Object Str );
11-
use MetaCPAN::Util qw( MAX_RESULT_WINDOW hit_total true false );
5+
use Const::Fast qw( const );
6+
use Hash::Merge qw( merge );
7+
use List::Util qw( min uniq );
8+
use Log::Contextual qw( :log :dlog );
9+
use MetaCPAN::ESConfig qw( es_doc_path );
10+
use MetaCPAN::Util qw( MAX_RESULT_WINDOW hit_total true false );
1211
use MooseX::StrictConstructor;
1312

1413
with 'MetaCPAN::Query::Role::Common';

lib/MetaCPAN/Script/Backup.pm

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ use Cpanel::JSON::XS qw( decode_json encode_json );
88
use DateTime ();
99
use IO::Zlib ();
1010
use Log::Contextual qw( :log :dlog );
11-
use MetaCPAN::Types::TypeTiny qw( Bool Int Path Str CommaSepOption );
11+
use MetaCPAN::Types::TypeTiny qw( Bool CommaSepOption Int Path Str );
1212
use MetaCPAN::Util qw( true false );
1313
use MetaCPAN::ESConfig qw( es_config );
1414
use Moose;

lib/MetaCPAN/Script/Contributor.pm

+1-3
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,7 @@ use warnings;
55

66
use Moose;
77

8-
use MetaCPAN::ESConfig qw( es_doc_path );
9-
use Log::Contextual qw( :log );
10-
use Ref::Util qw( is_arrayref );
8+
use Log::Contextual qw( :log );
119

1210
use MetaCPAN::Types::TypeTiny qw( Bool HashRef Int Str );
1311

lib/MetaCPAN/Script/Role/Contributor.pm

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use Moose::Role;
55
use Log::Contextual qw( :log :dlog );
66
use MetaCPAN::ESConfig qw( es_doc_path );
77
use MetaCPAN::Util qw( true false );
8-
use Ref::Util qw( is_arrayref );
8+
use Ref::Util ();
99

1010
sub update_contributors {
1111
my ( $self, $query ) = @_;

lib/MetaCPAN/Script/Snapshot.pm

-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ use DateTime ();
88
use DateTime::Format::ISO8601 ();
99
use HTTP::Tiny ();
1010
use Log::Contextual qw( :log :dlog );
11-
use MetaCPAN::Server::Config ();
1211
use MetaCPAN::Types::TypeTiny qw( ArrayRef Bool Str Uri );
1312
use Moose;
1413
use Sys::Hostname qw( hostname );

lib/MetaCPAN/Util.pm

-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@ use Ref::Util qw(
1818
is_plain_hashref
1919
is_ref
2020
);
21-
use Cpanel::JSON::XS ();
2221
use Sub::Exporter -setup => {
2322
exports => [ qw(
2423
root_dir

t/lib/MetaCPAN/TestServer.pm

-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@ use MetaCPAN::TestHelpers qw( fakecpan_dir );
2121
use MetaCPAN::Types::TypeTiny qw( HashRef Path );
2222
use MetaCPAN::Util qw( true false );
2323
use MooseX::Types::ElasticSearch qw( ES );
24-
use Search::Elasticsearch ();
2524
use Test::More;
2625

2726
has es_client => (

t/lib/MetaCPAN/Tests/Query.pm

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ use Test::Routine;
44

55
use MetaCPAN::ESConfig qw( es_doc_path );
66
use MetaCPAN::Server::Test ();
7-
use MetaCPAN::Types::TypeTiny qw( ES ArrayRef HashRef InstanceOf Str );
7+
use MetaCPAN::Types::TypeTiny qw( ES HashRef Str );
88
use Test::More;
99
use Try::Tiny qw( try );
1010

t/query.t

+2-2
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@ use warnings;
33

44
use lib 't/lib';
55

6-
use MetaCPAN::Query;
6+
use MetaCPAN::Query ();
77
use MetaCPAN::Server::Test ();
88
use Test::More;
9-
use Scalar::Util qw(weaken refaddr);
9+
use Scalar::Util qw( refaddr weaken );
1010

1111
my $es = MetaCPAN::Server::Test::es();
1212

t/query/release.t

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ use warnings;
33

44
use lib 't/lib';
55

6-
use MetaCPAN::Server::Test qw(query);
6+
use MetaCPAN::Server::Test qw( query );
77
use Test::More;
88

99
my $query = query()->release;

t/release/moose.t

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ use strict;
22
use warnings;
33
use lib 't/lib';
44

5-
use MetaCPAN::Server::Test qw( query es_result );
5+
use MetaCPAN::Server::Test qw( es_result query );
66
use MetaCPAN::Util qw( true false );
77
use Test::More;
88

t/release/multiple-modules.t

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ use strict;
22
use warnings;
33
use lib 't/lib';
44

5-
use MetaCPAN::Server::Test qw( query es_result );
5+
use MetaCPAN::Server::Test qw( es_result );
66
use MetaCPAN::Util qw(true false);
77
use Test::More;
88

t/release/pm-PL.t

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ use warnings;
33
use lib 't/lib';
44

55
use MetaCPAN::ESConfig qw( es_doc_path );
6-
use MetaCPAN::Server::Test qw( app GET query es test_psgi );
6+
use MetaCPAN::Server::Test qw( app es GET query test_psgi );
77
use Test::More;
88

99
my $query = query();

t/release/pod-with-data-token.t

-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ use strict;
22
use warnings;
33
use lib 't/lib';
44

5-
use Cpanel::JSON::XS ();
65
use MetaCPAN::TestHelpers qw( test_release );
76
use MetaCPAN::Util qw( true false );
87
use Test::More;

t/release/pod-with-generator.t

-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ use strict;
22
use warnings;
33
use lib 't/lib';
44

5-
use Cpanel::JSON::XS ();
65
use MetaCPAN::TestHelpers qw( test_release );
76
use MetaCPAN::Util qw(true false);
87
use Test::More;

0 commit comments

Comments
 (0)