Permalink
Browse files

Optimize shouldn't compile views.

  • Loading branch information...
taylorotwell committed Mar 10, 2015
1 parent cfa7fcb commit 7bf50d876e62c35ae86235c28b76acb49fb7184b
Showing with 0 additions and 32 deletions.
  1. +0 −32 src/Illuminate/Foundation/Console/OptimizeCommand.php
@@ -66,10 +66,6 @@ public function fire()
$this->info('Compiling common classes');
$this->compileClasses();
$this->info('Compiling views');
$this->compileViews();
}
else
{
@@ -126,34 +122,6 @@ protected function registerClassPreloaderCommand()
$this->getApplication()->add(new PreCompileCommand);
}
/**
* Compile all view files.
*
* @return void
*/
protected function compileViews()
{
foreach ($this->laravel['view']->getFinder()->getPaths() as $path)
{
foreach ($this->laravel['files']->allFiles($path) as $file)
{
try
{
$engine = $this->laravel['view']->getEngineFromPath($file);
}
catch (InvalidArgumentException $e)
{
continue;
}
if ($engine instanceof CompilerEngine)
{
$engine->getCompiler()->compile($file);
}
}
}
}
/**
* Get the console command options.
*

4 comments on commit 7bf50d8

@GrahamCampbell

This comment has been minimized.

Member

GrahamCampbell replied Mar 10, 2015

?

@reshadman

This comment has been minimized.

Contributor

reshadman replied Jul 6, 2016

@taylorotwell So how can they be optimised?

@GrahamCampbell

This comment has been minimized.

Member

GrahamCampbell replied Jul 6, 2016

It never "optimized" them anyway.

@reshadman

This comment has been minimized.

Contributor

reshadman replied Jul 9, 2016

@GrahamCampbell but the functionality was good. We were using it on minifying templates after deploy.

Please sign in to comment.