CS: PSR1/2

parent c4e9f5bd
......@@ -62,7 +62,6 @@ abstract class EloquentBaseRepository implements BaseRepository
return $this->model;
}
/**
* @inheritdoc
*/
......
......@@ -3,9 +3,9 @@
namespace Modules\Core\Sidebar;
use Maatwebsite\Sidebar\Menu;
use Maatwebsite\Sidebar\SidebarExtender;
use Modules\Core\Events\BuildingSidebar;
use Modules\User\Contracts\Authentication;
use Maatwebsite\Sidebar\SidebarExtender;
abstract class AbstractAdminSidebar implements SidebarExtender
{
......
......@@ -50,6 +50,7 @@ class MediaController extends Controller
if ($file->isImage()) {
return '<img src="' . Imagy::getThumbnail($file->path, 'smallThumb') . '"/>';
}
return '<i class="fa ' . FileHelper::getFaIcon($file->media_type) . '" style="font-size: 20px;"></i>';
})
->rawColumns(['thumbnail'])
......
......@@ -3,7 +3,6 @@
namespace Modules\Media\Providers;
use Illuminate\Contracts\Events\Dispatcher as DispatcherContract;
use Illuminate\Support\Facades\Validator;
use Illuminate\Support\ServiceProvider;
use Modules\Core\Events\BuildingSidebar;
use Modules\Core\Traits\CanGetSidebarClassForModule;
......
......@@ -11,9 +11,9 @@ namespace Modules\Media\Tests;
use Illuminate\Container\Container;
use Illuminate\Filesystem\Filesystem;
use Illuminate\Http\UploadedFile;
use Illuminate\Validation\Factory as Validator;
use Illuminate\Translation\FileLoader;
use Illuminate\Translation\Translator;
use Illuminate\Validation\Factory as Validator;
use Modules\Media\Validators\MaxFolderSizeRule;
final class MaxFolderSizeRuleTest extends MediaTestCase
......@@ -50,6 +50,7 @@ final class MaxFolderSizeRuleTest extends MediaTestCase
$validator = (new Validator($translator))->make(['file' => $directorySize], [
'file' => ['required', new MaxFolderSizeRule()],
]);
return $validator;
}
}
......@@ -2,13 +2,12 @@
namespace Modules\Translation\Http\Controllers\Api;
use Cartalyst\Sentinel\Laravel\Facades\Sentinel;
use Illuminate\Http\Request;
use Illuminate\Routing\Controller;
use Illuminate\Database\Eloquent\Collection;
use Cartalyst\Sentinel\Laravel\Facades\Sentinel;
use Modules\User\Traits\CanFindUserWithBearerToken;
use Modules\Translation\Services\TranslationRevisions;
use Modules\Translation\Repositories\TranslationRepository;
use Modules\Translation\Services\TranslationRevisions;
use Modules\User\Traits\CanFindUserWithBearerToken;
class TranslationController extends Controller
{
......
......@@ -2,8 +2,8 @@
namespace Modules\Translation\Repositories\File;
use Illuminate\Filesystem\Filesystem;
use Illuminate\Contracts\Translation\Loader;
use Illuminate\Filesystem\Filesystem;
use Modules\Translation\Repositories\FileTranslationRepository as FileTranslationRepositoryInterface;
class FileTranslationRepository implements FileTranslationRepositoryInterface
......
......@@ -71,7 +71,6 @@ class EloquentTranslationRepositoryTest extends BaseTranslationTest
],
];
$this->assertEquals($expected, $this->translation->allFormatted());
}
......
......@@ -2,10 +2,10 @@
namespace Modules\User\Entities\Sentinel;
use Illuminate\Contracts\Auth\Authenticatable as AuthenticatableContract;
use Illuminate\Auth\Authenticatable;
use Cartalyst\Sentinel\Laravel\Facades\Activation;
use Cartalyst\Sentinel\Users\EloquentUser;
use Illuminate\Auth\Authenticatable;
use Illuminate\Contracts\Auth\Authenticatable as AuthenticatableContract;
use Laracasts\Presenter\PresentableTrait;
use Modules\User\Entities\UserInterface;
use Modules\User\Entities\UserToken;
......@@ -114,7 +114,7 @@ class User extends EloquentUser implements UserInterface, AuthenticatableContrac
if (config()->has($config)) {
$function = config()->get($config);
$bound = $function->bindTo($this);
return $bound();
}
......
......@@ -17,6 +17,7 @@ class Sentinel implements LaravelGuard
if (SentinelFacade::check()) {
return true;
}
return false;
}
......@@ -47,6 +48,7 @@ class Sentinel implements LaravelGuard
if ($user = SentinelFacade::check()) {
return $user->id;
}
return null;
}
......
......@@ -11,6 +11,7 @@ use Modules\Core\Traits\CanPublishConfiguration;
use Modules\User\Contracts\Authentication;
use Modules\User\Entities\UserToken;
use Modules\User\Events\Handlers\RegisterUserSidebar;
use Modules\User\Guards\Sentinel;
use Modules\User\Http\Middleware\AuthorisedApiToken;
use Modules\User\Http\Middleware\AuthorisedApiTokenAdmin;
use Modules\User\Http\Middleware\GuestMiddleware;
......@@ -21,7 +22,6 @@ use Modules\User\Repositories\Eloquent\EloquentUserTokenRepository;
use Modules\User\Repositories\RoleRepository;
use Modules\User\Repositories\UserRepository;
use Modules\User\Repositories\UserTokenRepository;
use Modules\User\Guards\Sentinel;
class UserServiceProvider extends ServiceProvider
{
......
......@@ -108,7 +108,7 @@ class EntityGenerator extends Generator
$this->getContentForStub('admin-controller.stub', $entity)
);
}
/**
* Generate the requests for the given entity
*
......
......@@ -583,4 +583,4 @@ class ModuleScaffoldTest extends BaseTestCase
return $controllerFile;
}
}
\ No newline at end of file
}
......@@ -6,6 +6,7 @@ if (! function_exists('module_version')) {
if (is_core_module($module->name) === true) {
return \Modules\Core\Foundation\AsgardCms::VERSION;
}
return $module->version;
}
}
<?php
return [
/*
|--------------------------------------------------------------------------
......
......@@ -55,7 +55,7 @@ return [
'public' => [
'driver' => 'local',
'root' => storage_path('app/public'),
'url' => env('APP_URL').'/storage',
'url' => env('APP_URL') . '/storage',
'visibility' => 'public',
],
......
<?php
return [
/*
|--------------------------------------------------------------------------
......
......@@ -124,7 +124,7 @@ return [
'cookie' => env(
'SESSION_COOKIE',
str_slug(env('APP_NAME', 'laravel'), '_').'_session'
str_slug(env('APP_NAME', 'laravel'), '_') . '_session'
),
/*
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment