Skip to content

Commit

Permalink
remove deprecated code
Browse files Browse the repository at this point in the history
  • Loading branch information
kraih committed Jun 1, 2016
1 parent 8c0325d commit d3e6903
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 50 deletions.
6 changes: 5 additions & 1 deletion Changes
@@ -1,5 +1,9 @@

6.63 2016-06-01
6.63 2016-06-02
- Removed deprecated check method from Mojo::Server::Morbo.
- Removed deprecated build, compile and interpret methods from Mojo::Template.
- Removed deprecated multi_accept methods from Mojo::IOLoop,
Mojo::IOLoop::Server and Mojo::Server::Daemon.
- Updated jQuery to version 2.2.4.
- Improved generator commands not to overwrite existing files.

Expand Down
8 changes: 1 addition & 7 deletions lib/Mojo/IOLoop.pm
Expand Up @@ -9,7 +9,7 @@ use Mojo::IOLoop::Delay;
use Mojo::IOLoop::Server;
use Mojo::IOLoop::Stream;
use Mojo::Reactor::Poll;
use Mojo::Util qw(deprecated md5_sum steady_time);
use Mojo::Util qw(md5_sum steady_time);
use Scalar::Util qw(blessed weaken);

use constant DEBUG => $ENV{MOJO_IOLOOP_DEBUG} || 0;
Expand Down Expand Up @@ -74,12 +74,6 @@ sub delay {

sub is_running { _instance(shift)->reactor->is_running }

# DEPRECATED!
sub multi_accept {
deprecated 'Mojo::IOLoop::multi_accept is DEPRECATED';
@_ > 1 ? $_[0] : undef;
}

sub next_tick {
my ($self, $cb) = (_instance(shift), @_);
weaken $self;
Expand Down
7 changes: 0 additions & 7 deletions lib/Mojo/IOLoop/Server.pm
Expand Up @@ -6,7 +6,6 @@ use File::Basename 'dirname';
use File::Spec::Functions 'catfile';
use IO::Socket::IP;
use Mojo::IOLoop;
use Mojo::Util 'deprecated';
use Scalar::Util 'weaken';
use Socket qw(IPPROTO_TCP TCP_NODELAY);

Expand Down Expand Up @@ -102,12 +101,6 @@ sub listen {
$tls->{SSL_version} = $args->{tls_version} if $args->{tls_version};
}

# DEPRECATED!
sub multi_accept {
deprecated 'Mojo::IOLoop::Server::multi_accept is DEPRECATED';
@_ > 1 ? $_[0] : undef;
}

sub port { shift->{handle}->sockport }

sub start {
Expand Down
8 changes: 1 addition & 7 deletions lib/Mojo/Server/Daemon.pm
Expand Up @@ -5,7 +5,7 @@ use Carp 'croak';
use Mojo::IOLoop;
use Mojo::Transaction::WebSocket;
use Mojo::URL;
use Mojo::Util qw(deprecated term_escape);
use Mojo::Util 'term_escape';
use Mojo::WebSocket 'server_handshake';
use Scalar::Util 'weaken';

Expand All @@ -26,12 +26,6 @@ sub DESTROY {
$loop->remove($_) for @{$self->acceptors};
}

# DEPRECATED!
sub multi_accept {
deprecated 'Mojo::Server::Daemon::multi_accept is DEPRECATED';
@_ > 1 ? $_[0] : undef;
}

sub run {
my $self = shift;

Expand Down
9 changes: 1 addition & 8 deletions lib/Mojo/Server/Morbo.pm
Expand Up @@ -5,19 +5,12 @@ use Mojo::Base -base;
# effects of sudden, intense global warming.
# Morbo: Morbo is pleased but sticky."
use Mojo::Server::Daemon;
use Mojo::Util qw(deprecated files);
use Mojo::Util 'files';
use POSIX 'WNOHANG';

has daemon => sub { Mojo::Server::Daemon->new };
has watch => sub { [qw(lib templates)] };

# DEPRECATED!
sub check {
deprecated 'Mojo::Server::Morbo::check is DEPRECATED'
. ' in favor of Mojo::Server::Morbo::modified_files';
return shift->modified_files->[0];
}

sub modified_files {
my $self = shift;

Expand Down
21 changes: 1 addition & 20 deletions lib/Mojo/Template.pm
Expand Up @@ -4,7 +4,7 @@ use Mojo::Base -base;
use Carp 'croak';
use Mojo::ByteStream;
use Mojo::Exception;
use Mojo::Util qw(decode deprecated encode monkey_patch slurp);
use Mojo::Util qw(decode encode monkey_patch slurp);

use constant DEBUG => $ENV{MOJO_TEMPLATE_DEBUG} || 0;

Expand All @@ -23,25 +23,6 @@ has tag_start => '<%';
has tag_end => '%>';
has tree => sub { [] };

# DEPRECATED!
sub build {
deprecated 'Mojo::Template::build is DEPRECATED';
return shift;
}

# DEPRECATED!
sub compile {
deprecated 'Mojo::Template::compile is DEPRECATED';
return undef;
}

# DEPRECATED!
sub interpret {
deprecated 'Mojo::Template::compile is DEPRECATED'
. ' in favor of Mojo::Template::process';
shift->process(@_);
}

sub parse {
my ($self, $template) = @_;

Expand Down

0 comments on commit d3e6903

Please sign in to comment.