for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
use Illuminate\Console\Command;
class ClearAssetsCommand extends Command
You can fix this by adding a namespace to your class:
namespace YourVendor; class YourClass { }
When choosing a vendor namespace, try to pick something that is not too generic to avoid conflicts with other libraries.
{
/**
* The console command name.
*
* @var string
*/
protected $name = 'assets:clear';
* The console command description.
protected $description = 'Remove generated assets automatically';
* Execute the console command.
* @return void
public function fire()
File::deleteDirectory(public_path().'/assets');
$this->info('Assets cleared!');
}
* Get the console command arguments.
* @return array
protected function getArguments()
return [];
* Get the console command options.
protected function getOptions()
You can fix this by adding a namespace to your class:
When choosing a vendor namespace, try to pick something that is not too generic to avoid conflicts with other libraries.