protected function replaceNamespace(string $stub) : string
{
if (method_exists($this->laravel, 'getNameSpace')) {
$namespace = $this->laravel->getNamespace() . 'Transformers';
} else {
$namespace = 'App\\Transformers';
}
$stub = str_replace('DummyNamespace', $namespace, $stub);
return $stub;
}