diff --git a/app/Console/Commands/Inspire.php b/app/Console/Commands/Inspire.php deleted file mode 100644 index db9ab854..00000000 --- a/app/Console/Commands/Inspire.php +++ /dev/null @@ -1,33 +0,0 @@ -comment(PHP_EOL.Inspiring::quote().PHP_EOL); - } -} diff --git a/app/Console/Kernel.php b/app/Console/Kernel.php index 71c519d3..622e774b 100644 --- a/app/Console/Kernel.php +++ b/app/Console/Kernel.php @@ -13,7 +13,7 @@ class Kernel extends ConsoleKernel * @var array */ protected $commands = [ - // Commands\Inspire::class, + // ]; /** @@ -27,4 +27,14 @@ class Kernel extends ConsoleKernel // $schedule->command('inspire') // ->hourly(); } + + /** + * Register the Closure based commands for the application. + * + * @return void + */ + protected function commands() + { + require base_path('routes/console.php'); + } } diff --git a/app/Events/Event.php b/app/Events/Event.php deleted file mode 100644 index ba2f8883..00000000 --- a/app/Events/Event.php +++ /dev/null @@ -1,8 +0,0 @@ -renderExceptionWithWhoops($exc); - } + return parent::render($request, $exception); + } - if ($exc instanceof ModelNotFoundException) { - $exc = new NotFoundHttpException($exc->getMessage(), $exc); + /** + * Convert an authentication exception into an unauthenticated response. + * + * @param \Illuminate\Http\Request $request + * @param \Illuminate\Auth\AuthenticationException $exception + * @return \Illuminate\Http\Response + */ + protected function unauthenticated($request, AuthenticationException $exception) + { + if ($request->expectsJson()) { + return response()->json(['error' => 'Unauthenticated.'], 401); } - - if ($exc instanceof TokenMismatchException) { - return redirect()->back() - ->withInput($request->except('password', '_token')) - ->withErrors('Validation Token has expired. Please try again', 'csrf'); - } - - return parent::render($request, $exc); + return redirect()->guest('login'); } /** @@ -70,7 +69,7 @@ class Handler extends ExceptionHandler * @param \Exception $exc * @return \Illuminate\Http\Response */ - protected function renderExceptionWithWhoops(Exception $exc) + protected function renderExceptionWithWhoops(Exception $exception) { $whoops = new \Whoops\Run; $handler = new \Whoops\Handler\PrettyPageHandler(); @@ -79,7 +78,7 @@ class Handler extends ExceptionHandler }); $whoops->pushHandler($handler); - $flattened = FlattenException::create($exc); + $flattened = FlattenException::create($exception); return new \Illuminate\Http\Response( $whoops->handleException($exc), diff --git a/app/Http/Controllers/Auth/ForgotPasswordController.php b/app/Http/Controllers/Auth/ForgotPasswordController.php new file mode 100644 index 00000000..6a247fef --- /dev/null +++ b/app/Http/Controllers/Auth/ForgotPasswordController.php @@ -0,0 +1,32 @@ +middleware('guest'); + } +} diff --git a/app/Http/Controllers/Auth/LoginController.php b/app/Http/Controllers/Auth/LoginController.php new file mode 100644 index 00000000..2abd9e04 --- /dev/null +++ b/app/Http/Controllers/Auth/LoginController.php @@ -0,0 +1,39 @@ +middleware('guest', ['except' => 'logout']); + } +} diff --git a/app/Http/Controllers/Auth/AuthController.php b/app/Http/Controllers/Auth/RegisterController.php similarity index 67% rename from app/Http/Controllers/Auth/AuthController.php rename to app/Http/Controllers/Auth/RegisterController.php index a100dd6e..34c376cf 100644 --- a/app/Http/Controllers/Auth/AuthController.php +++ b/app/Http/Controllers/Auth/RegisterController.php @@ -5,39 +5,38 @@ namespace App\Http\Controllers\Auth; use App\User; use Validator; use App\Http\Controllers\Controller; -use Illuminate\Foundation\Auth\ThrottlesLogins; -use Illuminate\Foundation\Auth\AuthenticatesAndRegistersUsers; +use Illuminate\Foundation\Auth\RegistersUsers; -class AuthController extends Controller +class RegisterController extends Controller { /* |-------------------------------------------------------------------------- - | Registration & Login Controller + | Register Controller |-------------------------------------------------------------------------- | - | This controller handles the registration of new users, as well as the - | authentication of existing users. By default, this controller uses - | a simple trait to add these behaviors. Why don't you explore it? + | This controller handles the registration of new users as well as their + | validation and creation. By default this controller uses a trait to + | provide this functionality without requiring any additional code. | */ - use AuthenticatesAndRegistersUsers, ThrottlesLogins; + use RegistersUsers; /** * Where to redirect users after login / registration. * * @var string */ - protected $redirectTo = '/'; + protected $redirectTo = '/home'; /** - * Create a new authentication controller instance. + * Create a new controller instance. * * @return void */ public function __construct() { - $this->middleware($this->guestMiddleware(), ['except' => 'logout']); + $this->middleware('guest'); } /** diff --git a/app/Http/Controllers/Auth/PasswordController.php b/app/Http/Controllers/Auth/ResetPasswordController.php similarity index 82% rename from app/Http/Controllers/Auth/PasswordController.php rename to app/Http/Controllers/Auth/ResetPasswordController.php index 66f77366..c73bf99f 100644 --- a/app/Http/Controllers/Auth/PasswordController.php +++ b/app/Http/Controllers/Auth/ResetPasswordController.php @@ -5,7 +5,7 @@ namespace App\Http\Controllers\Auth; use App\Http\Controllers\Controller; use Illuminate\Foundation\Auth\ResetsPasswords; -class PasswordController extends Controller +class ResetPasswordController extends Controller { /* |-------------------------------------------------------------------------- @@ -21,12 +21,12 @@ class PasswordController extends Controller use ResetsPasswords; /** - * Create a new password controller instance. + * Create a new controller instance. * * @return void */ public function __construct() { - $this->middleware($this->guestMiddleware()); + $this->middleware('guest'); } } diff --git a/app/Http/Controllers/Controller.php b/app/Http/Controllers/Controller.php index d492e0b3..03e02a23 100644 --- a/app/Http/Controllers/Controller.php +++ b/app/Http/Controllers/Controller.php @@ -6,9 +6,8 @@ use Illuminate\Foundation\Bus\DispatchesJobs; use Illuminate\Routing\Controller as BaseController; use Illuminate\Foundation\Validation\ValidatesRequests; use Illuminate\Foundation\Auth\Access\AuthorizesRequests; -use Illuminate\Foundation\Auth\Access\AuthorizesResources; class Controller extends BaseController { - use AuthorizesRequests, AuthorizesResources, DispatchesJobs, ValidatesRequests; + use AuthorizesRequests, DispatchesJobs, ValidatesRequests; } diff --git a/app/Http/Kernel.php b/app/Http/Kernel.php index ebad4d16..0a782b36 100644 --- a/app/Http/Kernel.php +++ b/app/Http/Kernel.php @@ -29,11 +29,13 @@ class Kernel extends HttpKernel \Illuminate\Session\Middleware\StartSession::class, \Illuminate\View\Middleware\ShareErrorsFromSession::class, \App\Http\Middleware\VerifyCsrfToken::class, + \Illuminate\Routing\Middleware\SubstituteBindings::class, \App\Http\Middleware\LinkHeadersMiddleware::class, ], 'api' => [ 'throttle:60,1', + 'bindings', ], ]; @@ -47,7 +49,7 @@ class Kernel extends HttpKernel protected $routeMiddleware = [ 'auth' => \App\Http\Middleware\Authenticate::class, 'auth.basic' => \Illuminate\Auth\Middleware\AuthenticateWithBasicAuth::class, - 'can' => \Illuminate\Foundation\Http\Middleware\Authorize::class, + 'can' => \Illuminate\Auth\Middleware\Authorize::class, 'guest' => \App\Http\Middleware\RedirectIfAuthenticated::class, 'myauth' => \App\Http\Middleware\MyAuthMiddleware::class, 'throttle' => \Illuminate\Routing\Middleware\ThrottleRequests::class, diff --git a/app/Http/Middleware/Authenticate.php b/app/Http/Middleware/Authenticate.php deleted file mode 100644 index 67abcaea..00000000 --- a/app/Http/Middleware/Authenticate.php +++ /dev/null @@ -1,30 +0,0 @@ -guest()) { - if ($request->ajax() || $request->wantsJson()) { - return response('Unauthorized.', 401); - } else { - return redirect()->guest('login'); - } - } - - return $next($request); - } -} diff --git a/app/Http/Requests/Request.php b/app/Http/Requests/Request.php deleted file mode 100644 index 76b2ffd4..00000000 --- a/app/Http/Requests/Request.php +++ /dev/null @@ -1,10 +0,0 @@ -registerPolicies($gate); + $this->registerPolicies(); // } diff --git a/app/Providers/BroadcastServiceProvider.php b/app/Providers/BroadcastServiceProvider.php new file mode 100644 index 00000000..1dcf8d28 --- /dev/null +++ b/app/Providers/BroadcastServiceProvider.php @@ -0,0 +1,26 @@ +id === (int) $userId; + }); + } +} diff --git a/app/Providers/EventServiceProvider.php b/app/Providers/EventServiceProvider.php index 58ce9624..ed0e3e5b 100644 --- a/app/Providers/EventServiceProvider.php +++ b/app/Providers/EventServiceProvider.php @@ -2,7 +2,7 @@ namespace App\Providers; -use Illuminate\Contracts\Events\Dispatcher as DispatcherContract; +use Illuminate\Support\Facades\Event; use Illuminate\Foundation\Support\Providers\EventServiceProvider as ServiceProvider; class EventServiceProvider extends ServiceProvider @@ -21,12 +21,11 @@ class EventServiceProvider extends ServiceProvider /** * Register any other events for your application. * - * @param \Illuminate\Contracts\Events\Dispatcher $events * @return void */ - public function boot(DispatcherContract $events) + public function boot() { - parent::boot($events); + parent::boot(); // } diff --git a/app/Providers/RouteServiceProvider.php b/app/Providers/RouteServiceProvider.php index bde08819..0ec8fbc2 100644 --- a/app/Providers/RouteServiceProvider.php +++ b/app/Providers/RouteServiceProvider.php @@ -2,7 +2,7 @@ namespace App\Providers; -use Illuminate\Routing\Router; +use Illuminate\Support\Facades\Route; use Illuminate\Foundation\Support\Providers\RouteServiceProvider as ServiceProvider; class RouteServiceProvider extends ServiceProvider @@ -22,22 +22,23 @@ class RouteServiceProvider extends ServiceProvider * @param \Illuminate\Routing\Router $router * @return void */ - public function boot(Router $router) + public function boot() { // - parent::boot($router); + parent::boot(); } /** * Define the routes for the application. * - * @param \Illuminate\Routing\Router $router * @return void */ - public function map(Router $router) + public function map() { - $this->mapWebRoutes($router); + $this->mapWebRoutes(); + + $this->mapApiRoutes(); // } @@ -47,15 +48,33 @@ class RouteServiceProvider extends ServiceProvider * * These routes all receive session state, CSRF protection, etc. * - * @param \Illuminate\Routing\Router $router * @return void */ - protected function mapWebRoutes(Router $router) + protected function mapWebRoutes() { - $router->group([ - 'namespace' => $this->namespace, 'middleware' => 'web', + Route::group([ + 'middleware' => 'web', + 'namespace' => $this->namespace, ], function ($router) { - require app_path('Http/routes.php'); + require base_path('routes/web.php'); + }); + } + + /** + * Define the "api" routes for the application. + * + * These routes are typically stateless. + * + * @return void + */ + protected function mapApiRoutes() + { + Route::group([ + 'middleware' => 'api', + 'namespace' => $this->namespace, + 'prefix' => 'api' + ], function ($router) { + require base_path('routes/api.php'); }); } } diff --git a/app/User.php b/app/User.php index 75741ae4..bfd96a6a 100644 --- a/app/User.php +++ b/app/User.php @@ -2,10 +2,13 @@ namespace App; +use Illuminate\Notifications\Notifiable; use Illuminate\Foundation\Auth\User as Authenticatable; class User extends Authenticatable { + use Notifiable; + /** * The attributes that are mass assignable. * diff --git a/composer.json b/composer.json index b1a8b9c0..f4656161 100644 --- a/composer.json +++ b/composer.json @@ -1,13 +1,13 @@ { "name": "jonnybarnes/jonnybarnes.uk", - "description": "The code for jonnybanres.uk, based on Laravel 5.2", + "description": "The code for jonnybanres.uk, based on Laravel 5.3", "keywords": ["framework", "laravel", "indieweb"], "license": "CC0-1.0", "type": "project", "require": { "ext-intl": "*", "php": ">=7.0.0", - "laravel/framework": "5.2.*", + "laravel/framework": "5.3.*", "jonnybarnes/indieweb": "dev-master", "jonnybarnes/webmentions-parser": "dev-master", "guzzlehttp/guzzle": "~6.0", @@ -27,8 +27,8 @@ "fzaninotto/faker": "~1.4", "mockery/mockery": "0.9.*", "phpunit/phpunit": "~5.0", - "symfony/css-selector": "2.8.*|3.0.*", - "symfony/dom-crawler": "2.8.*|3.0.*", + "symfony/css-selector": "3.1.*", + "symfony/dom-crawler": "3.1.*", "barryvdh/laravel-debugbar": "~2.0", "filp/whoops": "~2.0" }, diff --git a/composer.lock b/composer.lock index bcd7f6bd..1da9d527 100644 --- a/composer.lock +++ b/composer.lock @@ -4,8 +4,8 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", "This file is @generated automatically" ], - "hash": "f353d67fde3ccad2d10d6ded9ef3778a", - "content-hash": "74cc6cb201324d06d26c1df3bcc92475", + "hash": "7a7231eebef62c0fb518cf030d531d95", + "content-hash": "3815acce9215a64c27a68ada0123dc48", "packages": [ { "name": "anahkiasen/underscore-php", @@ -1533,16 +1533,16 @@ }, { "name": "laravel/framework", - "version": "v5.2.45", + "version": "v5.3.6", "source": { "type": "git", "url": "https://github.com/laravel/framework.git", - "reference": "2a79f920d5584ec6df7cf996d922a742d11095d1" + "reference": "c63a7fb7066fea2bce91ace5c830c01d503abe6c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laravel/framework/zipball/2a79f920d5584ec6df7cf996d922a742d11095d1", - "reference": "2a79f920d5584ec6df7cf996d922a742d11095d1", + "url": "https://api.github.com/repos/laravel/framework/zipball/c63a7fb7066fea2bce91ace5c830c01d503abe6c", + "reference": "c63a7fb7066fea2bce91ace5c830c01d503abe6c", "shasum": "" }, "require": { @@ -1555,20 +1555,20 @@ "monolog/monolog": "~1.11", "mtdowling/cron-expression": "~1.0", "nesbot/carbon": "~1.20", - "paragonie/random_compat": "~1.4", - "php": ">=5.5.9", + "paragonie/random_compat": "~1.4|~2.0", + "php": ">=5.6.4", "psy/psysh": "0.7.*", + "ramsey/uuid": "~3.0", "swiftmailer/swiftmailer": "~5.1", - "symfony/console": "2.8.*|3.0.*", - "symfony/debug": "2.8.*|3.0.*", - "symfony/finder": "2.8.*|3.0.*", - "symfony/http-foundation": "2.8.*|3.0.*", - "symfony/http-kernel": "2.8.*|3.0.*", - "symfony/polyfill-php56": "~1.0", - "symfony/process": "2.8.*|3.0.*", - "symfony/routing": "2.8.*|3.0.*", - "symfony/translation": "2.8.*|3.0.*", - "symfony/var-dumper": "2.8.*|3.0.*", + "symfony/console": "3.1.*", + "symfony/debug": "3.1.*", + "symfony/finder": "3.1.*", + "symfony/http-foundation": "3.1.*", + "symfony/http-kernel": "3.1.*", + "symfony/process": "3.1.*", + "symfony/routing": "3.1.*", + "symfony/translation": "3.1.*", + "symfony/var-dumper": "3.1.*", "vlucas/phpdotenv": "~2.2" }, "replace": { @@ -1606,10 +1606,10 @@ "aws/aws-sdk-php": "~3.0", "mockery/mockery": "~0.9.4", "pda/pheanstalk": "~3.0", - "phpunit/phpunit": "~4.1", + "phpunit/phpunit": "~5.4", "predis/predis": "~1.0", - "symfony/css-selector": "2.8.*|3.0.*", - "symfony/dom-crawler": "2.8.*|3.0.*" + "symfony/css-selector": "3.1.*", + "symfony/dom-crawler": "3.1.*" }, "suggest": { "aws/aws-sdk-php": "Required to use the SQS queue driver and SES mail driver (~3.0).", @@ -1621,20 +1621,17 @@ "pda/pheanstalk": "Required to use the beanstalk queue driver (~3.0).", "predis/predis": "Required to use the redis cache and queue drivers (~1.0).", "pusher/pusher-php-server": "Required to use the Pusher broadcast driver (~2.0).", - "symfony/css-selector": "Required to use some of the crawler integration testing tools (2.8.*|3.0.*).", - "symfony/dom-crawler": "Required to use most of the crawler integration testing tools (2.8.*|3.0.*).", - "symfony/psr-http-message-bridge": "Required to use psr7 bridging features (0.2.*)." + "symfony/css-selector": "Required to use some of the crawler integration testing tools (3.1.*).", + "symfony/dom-crawler": "Required to use most of the crawler integration testing tools (3.1.*).", + "symfony/psr-http-message-bridge": "Required to psr7 bridging features (0.2.*)." }, "type": "library", "extra": { "branch-alias": { - "dev-master": "5.2-dev" + "dev-master": "5.3-dev" } }, "autoload": { - "classmap": [ - "src/Illuminate/Queue/IlluminateQueueClosure.php" - ], "files": [ "src/Illuminate/Foundation/helpers.php", "src/Illuminate/Support/helpers.php" @@ -1650,16 +1647,16 @@ "authors": [ { "name": "Taylor Otwell", - "email": "taylorotwell@gmail.com" + "email": "taylor@laravel.com" } ], "description": "The Laravel Framework.", - "homepage": "http://laravel.com", + "homepage": "https://laravel.com", "keywords": [ "framework", "laravel" ], - "time": "2016-08-26 11:44:52" + "time": "2016-09-01 14:06:47" }, { "name": "lcobucci/jwt", @@ -2351,16 +2348,16 @@ }, { "name": "paragonie/random_compat", - "version": "v1.4.1", + "version": "v2.0.2", "source": { "type": "git", "url": "https://github.com/paragonie/random_compat.git", - "reference": "c7e26a21ba357863de030f0b9e701c7d04593774" + "reference": "088c04e2f261c33bed6ca5245491cfca69195ccf" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/paragonie/random_compat/zipball/c7e26a21ba357863de030f0b9e701c7d04593774", - "reference": "c7e26a21ba357863de030f0b9e701c7d04593774", + "url": "https://api.github.com/repos/paragonie/random_compat/zipball/088c04e2f261c33bed6ca5245491cfca69195ccf", + "reference": "088c04e2f261c33bed6ca5245491cfca69195ccf", "shasum": "" }, "require": { @@ -2395,7 +2392,7 @@ "pseudorandom", "random" ], - "time": "2016-03-18 20:34:03" + "time": "2016-04-03 06:00:07" }, { "name": "patchwork/utf8", @@ -3064,16 +3061,16 @@ }, { "name": "symfony/console", - "version": "v3.0.9", + "version": "v3.1.4", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "926061e74229e935d3c5b4e9ba87237316c6693f" + "reference": "8ea494c34f0f772c3954b5fbe00bffc5a435e563" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/926061e74229e935d3c5b4e9ba87237316c6693f", - "reference": "926061e74229e935d3c5b4e9ba87237316c6693f", + "url": "https://api.github.com/repos/symfony/console/zipball/8ea494c34f0f772c3954b5fbe00bffc5a435e563", + "reference": "8ea494c34f0f772c3954b5fbe00bffc5a435e563", "shasum": "" }, "require": { @@ -3093,7 +3090,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "3.1-dev" } }, "autoload": { @@ -3120,20 +3117,20 @@ ], "description": "Symfony Console Component", "homepage": "https://symfony.com", - "time": "2016-07-30 07:22:48" + "time": "2016-08-19 06:48:39" }, { "name": "symfony/debug", - "version": "v3.0.9", + "version": "v3.1.4", "source": { "type": "git", "url": "https://github.com/symfony/debug.git", - "reference": "697c527acd9ea1b2d3efac34d9806bf255278b0a" + "reference": "34f6ac18c2974ca5fce68adf419ee7d15def6f11" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/debug/zipball/697c527acd9ea1b2d3efac34d9806bf255278b0a", - "reference": "697c527acd9ea1b2d3efac34d9806bf255278b0a", + "url": "https://api.github.com/repos/symfony/debug/zipball/34f6ac18c2974ca5fce68adf419ee7d15def6f11", + "reference": "34f6ac18c2974ca5fce68adf419ee7d15def6f11", "shasum": "" }, "require": { @@ -3150,7 +3147,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "3.1-dev" } }, "autoload": { @@ -3177,7 +3174,7 @@ ], "description": "Symfony Debug Component", "homepage": "https://symfony.com", - "time": "2016-07-30 07:22:48" + "time": "2016-08-23 13:39:15" }, { "name": "symfony/event-dispatcher", @@ -3241,16 +3238,16 @@ }, { "name": "symfony/finder", - "version": "v3.0.9", + "version": "v3.1.4", "source": { "type": "git", "url": "https://github.com/symfony/finder.git", - "reference": "3eb4e64c6145ef8b92adefb618a74ebdde9e3fe9" + "reference": "e568ef1784f447a0e54dcb6f6de30b9747b0f577" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/finder/zipball/3eb4e64c6145ef8b92adefb618a74ebdde9e3fe9", - "reference": "3eb4e64c6145ef8b92adefb618a74ebdde9e3fe9", + "url": "https://api.github.com/repos/symfony/finder/zipball/e568ef1784f447a0e54dcb6f6de30b9747b0f577", + "reference": "e568ef1784f447a0e54dcb6f6de30b9747b0f577", "shasum": "" }, "require": { @@ -3259,7 +3256,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "3.1-dev" } }, "autoload": { @@ -3286,20 +3283,20 @@ ], "description": "Symfony Finder Component", "homepage": "https://symfony.com", - "time": "2016-06-29 05:40:00" + "time": "2016-08-26 12:04:02" }, { "name": "symfony/http-foundation", - "version": "v3.0.9", + "version": "v3.1.4", "source": { "type": "git", "url": "https://github.com/symfony/http-foundation.git", - "reference": "49ba00f8ede742169cb6b70abe33243f4d673f82" + "reference": "63592e00fd90632b57ee50220a1ddb29b6bf3bb4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-foundation/zipball/49ba00f8ede742169cb6b70abe33243f4d673f82", - "reference": "49ba00f8ede742169cb6b70abe33243f4d673f82", + "url": "https://api.github.com/repos/symfony/http-foundation/zipball/63592e00fd90632b57ee50220a1ddb29b6bf3bb4", + "reference": "63592e00fd90632b57ee50220a1ddb29b6bf3bb4", "shasum": "" }, "require": { @@ -3312,7 +3309,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "3.1-dev" } }, "autoload": { @@ -3339,20 +3336,20 @@ ], "description": "Symfony HttpFoundation Component", "homepage": "https://symfony.com", - "time": "2016-07-17 13:54:30" + "time": "2016-08-22 12:11:19" }, { "name": "symfony/http-kernel", - "version": "v3.0.9", + "version": "v3.1.4", "source": { "type": "git", "url": "https://github.com/symfony/http-kernel.git", - "reference": "d97ba4425e36e79c794e7d14ff36f00f081b37b3" + "reference": "aeda215d6b01f119508c090d2a09ebb5b0bc61f3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-kernel/zipball/d97ba4425e36e79c794e7d14ff36f00f081b37b3", - "reference": "d97ba4425e36e79c794e7d14ff36f00f081b37b3", + "url": "https://api.github.com/repos/symfony/http-kernel/zipball/aeda215d6b01f119508c090d2a09ebb5b0bc61f3", + "reference": "aeda215d6b01f119508c090d2a09ebb5b0bc61f3", "shasum": "" }, "require": { @@ -3394,7 +3391,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "3.1-dev" } }, "autoload": { @@ -3421,7 +3418,7 @@ ], "description": "Symfony HttpKernel Component", "homepage": "https://symfony.com", - "time": "2016-07-30 09:10:37" + "time": "2016-09-03 15:28:24" }, { "name": "symfony/polyfill-mbstring", @@ -3592,16 +3589,16 @@ }, { "name": "symfony/process", - "version": "v3.0.9", + "version": "v3.1.4", "source": { "type": "git", "url": "https://github.com/symfony/process.git", - "reference": "768debc5996f599c4372b322d9061dba2a4bf505" + "reference": "e64e93041c80e77197ace5ab9385dedb5a143697" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/process/zipball/768debc5996f599c4372b322d9061dba2a4bf505", - "reference": "768debc5996f599c4372b322d9061dba2a4bf505", + "url": "https://api.github.com/repos/symfony/process/zipball/e64e93041c80e77197ace5ab9385dedb5a143697", + "reference": "e64e93041c80e77197ace5ab9385dedb5a143697", "shasum": "" }, "require": { @@ -3610,7 +3607,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "3.1-dev" } }, "autoload": { @@ -3637,20 +3634,20 @@ ], "description": "Symfony Process Component", "homepage": "https://symfony.com", - "time": "2016-07-28 11:13:34" + "time": "2016-08-16 14:58:24" }, { "name": "symfony/routing", - "version": "v3.0.9", + "version": "v3.1.4", "source": { "type": "git", "url": "https://github.com/symfony/routing.git", - "reference": "9038984bd9c05ab07280121e9e10f61a7231457b" + "reference": "8edf62498a1a4c57ba317664a4b698339c10cdf6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/routing/zipball/9038984bd9c05ab07280121e9e10f61a7231457b", - "reference": "9038984bd9c05ab07280121e9e10f61a7231457b", + "url": "https://api.github.com/repos/symfony/routing/zipball/8edf62498a1a4c57ba317664a4b698339c10cdf6", + "reference": "8edf62498a1a4c57ba317664a4b698339c10cdf6", "shasum": "" }, "require": { @@ -3679,7 +3676,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "3.1-dev" } }, "autoload": { @@ -3712,20 +3709,20 @@ "uri", "url" ], - "time": "2016-06-29 05:40:00" + "time": "2016-08-16 14:58:24" }, { "name": "symfony/translation", - "version": "v3.0.9", + "version": "v3.1.4", "source": { "type": "git", "url": "https://github.com/symfony/translation.git", - "reference": "eee6c664853fd0576f21ae25725cfffeafe83f26" + "reference": "a35edc277513c9bc0f063ca174c36b346f974528" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/translation/zipball/eee6c664853fd0576f21ae25725cfffeafe83f26", - "reference": "eee6c664853fd0576f21ae25725cfffeafe83f26", + "url": "https://api.github.com/repos/symfony/translation/zipball/a35edc277513c9bc0f063ca174c36b346f974528", + "reference": "a35edc277513c9bc0f063ca174c36b346f974528", "shasum": "" }, "require": { @@ -3749,7 +3746,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "3.1-dev" } }, "autoload": { @@ -3776,20 +3773,20 @@ ], "description": "Symfony Translation Component", "homepage": "https://symfony.com", - "time": "2016-07-30 07:22:48" + "time": "2016-08-05 08:37:39" }, { "name": "symfony/var-dumper", - "version": "v3.0.9", + "version": "v3.1.4", "source": { "type": "git", "url": "https://github.com/symfony/var-dumper.git", - "reference": "1f7e071aafc6676fcb6e3f0497f87c2397247377" + "reference": "62ee73706c421654a4c840028954510277f7dfc8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/var-dumper/zipball/1f7e071aafc6676fcb6e3f0497f87c2397247377", - "reference": "1f7e071aafc6676fcb6e3f0497f87c2397247377", + "url": "https://api.github.com/repos/symfony/var-dumper/zipball/62ee73706c421654a4c840028954510277f7dfc8", + "reference": "62ee73706c421654a4c840028954510277f7dfc8", "shasum": "" }, "require": { @@ -3805,7 +3802,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "3.1-dev" } }, "autoload": { @@ -3839,7 +3836,7 @@ "debug", "dump" ], - "time": "2016-07-26 08:03:56" + "time": "2016-08-31 09:05:42" }, { "name": "themattharris/tmhoauth", @@ -5512,16 +5509,16 @@ }, { "name": "symfony/css-selector", - "version": "v3.0.9", + "version": "v3.1.4", "source": { "type": "git", "url": "https://github.com/symfony/css-selector.git", - "reference": "b8999c1f33c224b2b66b38253f5e3a838d0d0115" + "reference": "2851e1932d77ce727776154d659b232d061e816a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/css-selector/zipball/b8999c1f33c224b2b66b38253f5e3a838d0d0115", - "reference": "b8999c1f33c224b2b66b38253f5e3a838d0d0115", + "url": "https://api.github.com/repos/symfony/css-selector/zipball/2851e1932d77ce727776154d659b232d061e816a", + "reference": "2851e1932d77ce727776154d659b232d061e816a", "shasum": "" }, "require": { @@ -5530,7 +5527,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "3.1-dev" } }, "autoload": { @@ -5561,20 +5558,20 @@ ], "description": "Symfony CssSelector Component", "homepage": "https://symfony.com", - "time": "2016-06-29 05:40:00" + "time": "2016-06-29 05:41:56" }, { "name": "symfony/dom-crawler", - "version": "v3.0.9", + "version": "v3.1.4", "source": { "type": "git", "url": "https://github.com/symfony/dom-crawler.git", - "reference": "dff8fecf1f56990d88058e3a1885c2a5f1b8e970" + "reference": "bb7395e8b1db3654de82b9f35d019958276de4d7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/dom-crawler/zipball/dff8fecf1f56990d88058e3a1885c2a5f1b8e970", - "reference": "dff8fecf1f56990d88058e3a1885c2a5f1b8e970", + "url": "https://api.github.com/repos/symfony/dom-crawler/zipball/bb7395e8b1db3654de82b9f35d019958276de4d7", + "reference": "bb7395e8b1db3654de82b9f35d019958276de4d7", "shasum": "" }, "require": { @@ -5590,7 +5587,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "3.1-dev" } }, "autoload": { @@ -5617,7 +5614,7 @@ ], "description": "Symfony DomCrawler Component", "homepage": "https://symfony.com", - "time": "2016-07-30 07:22:48" + "time": "2016-08-05 08:37:39" }, { "name": "symfony/yaml", diff --git a/config/app.php b/config/app.php index 76190440..5ac83ad3 100644 --- a/config/app.php +++ b/config/app.php @@ -2,6 +2,18 @@ return [ + /* + |-------------------------------------------------------------------------- + | Application Name + |-------------------------------------------------------------------------- + | + | This value is the name of your application. This value is used when the + | framework needs to place the application's name in a notification or + | any other location as required by the application or its packages. + */ + + 'name' => 'jonnybarnes.uk', + /* |-------------------------------------------------------------------------- | Application Environment @@ -151,6 +163,7 @@ return [ Illuminate\Foundation\Providers\FoundationServiceProvider::class, Illuminate\Hashing\HashServiceProvider::class, Illuminate\Mail\MailServiceProvider::class, + Illuminate\Notifications\NotificationServiceProvider::class, Illuminate\Pagination\PaginationServiceProvider::class, Illuminate\Pipeline\PipelineServiceProvider::class, Illuminate\Queue\QueueServiceProvider::class, @@ -166,6 +179,7 @@ return [ */ App\Providers\AppServiceProvider::class, App\Providers\AuthServiceProvider::class, + // App\Providers\BroadcastServiceProvider::class, App\Providers\EventServiceProvider::class, App\Providers\RouteServiceProvider::class, @@ -221,6 +235,7 @@ return [ 'Lang' => Illuminate\Support\Facades\Lang::class, 'Log' => Illuminate\Support\Facades\Log::class, 'Mail' => Illuminate\Support\Facades\Mail::class, + 'Notification' => Illuminate\Support\Facades\Notification::class, 'Password' => Illuminate\Support\Facades\Password::class, 'Queue' => Illuminate\Support\Facades\Queue::class, 'Redirect' => Illuminate\Support\Facades\Redirect::class, diff --git a/config/auth.php b/config/auth.php index 3fa7f491..97b29789 100644 --- a/config/auth.php +++ b/config/auth.php @@ -81,10 +81,6 @@ return [ | Resetting Passwords |-------------------------------------------------------------------------- | - | Here you may set the options for resetting passwords including the view - | that is your password reset e-mail. You may also set the name of the - | table that maintains all of the reset tokens for your application. - | | You may specify multiple password reset configurations if you have more | than one user table or model in the application and you want to have | separate password reset settings based on the specific user types. @@ -94,11 +90,9 @@ return [ | they have less time to be guessed. You may change this as needed. | */ - 'passwords' => [ 'users' => [ 'provider' => 'users', - 'email' => 'auth.emails.password', 'table' => 'password_resets', 'expire' => 60, ], diff --git a/config/broadcasting.php b/config/broadcasting.php index bf8b2dfe..19a59bad 100644 --- a/config/broadcasting.php +++ b/config/broadcasting.php @@ -11,11 +11,11 @@ return [ | framework when an event needs to be broadcast. You may set this to | any of the connections defined in the "connections" array below. | - | Supported: "pusher", "redis", "log" + | Supported: "pusher", "redis", "log", "null" | */ - 'default' => env('BROADCAST_DRIVER', 'pusher'), + 'default' => env('BROADCAST_DRIVER', 'null'), /* |-------------------------------------------------------------------------- @@ -49,6 +49,10 @@ return [ 'driver' => 'log', ], + 'null' => [ + 'driver' => 'null', + ], + ], ]; diff --git a/config/cache.php b/config/cache.php index 6b8ac914..1d3de874 100644 --- a/config/cache.php +++ b/config/cache.php @@ -51,6 +51,14 @@ return [ 'memcached' => [ 'driver' => 'memcached', + 'persistent_id' => env('MEMCACHED_PERSISTENT_ID'), + 'sasl' => [ + env('MEMCACHED_USERNAME'), + env('MEMCACHED_PASSWORD'), + ], + 'options' => [ + // Memcached::OPT_CONNECT_TIMEOUT => 2000, + ], 'servers' => [ [ 'host' => env('MEMCACHED_HOST', '127.0.0.1'), diff --git a/config/database.php b/config/database.php index 598a7ff3..f3549992 100644 --- a/config/database.php +++ b/config/database.php @@ -53,29 +53,30 @@ return [ ], 'mysql' => [ - 'driver' => 'mysql', - 'host' => env('DB_HOST', 'localhost'), - 'port' => env('DB_PORT', '3306'), - 'database' => env('DB_DATABASE', 'forge'), - 'username' => env('DB_USERNAME', 'forge'), - 'password' => env('DB_PASSWORD', ''), - 'charset' => 'utf8mb4', - 'collation' => 'utf8mb4_unicode_ci', - 'prefix' => '', - 'strict' => false, - 'engine' => null, + 'driver' => 'mysql', + 'host' => env('DB_HOST', 'localhost'), + 'port' => env('DB_PORT', '3306'), + 'database' => env('DB_DATABASE', 'forge'), + 'username' => env('DB_USERNAME', 'forge'), + 'password' => env('DB_PASSWORD', ''), + 'charset' => 'utf8', + 'collation' => 'utf8_unicode_ci', + 'prefix' => '', + 'strict' => true, + 'engine' => null, ], 'pgsql' => [ - 'driver' => 'pgsql', - 'host' => env('DB_HOST', 'localhost'), - 'port' => env('DB_PORT', '5432'), - 'database' => env('DB_DATABASE', 'forge'), - 'username' => env('DB_USERNAME', 'forge'), - 'password' => env('DB_PASSWORD', ''), - 'charset' => 'utf8', - 'prefix' => '', - 'schema' => 'public', + 'driver' => 'pgsql', + 'host' => env('DB_HOST', 'localhost'), + 'port' => env('DB_PORT', '5432'), + 'database' => env('DB_DATABASE', 'forge'), + 'username' => env('DB_USERNAME', 'forge'), + 'password' => env('DB_PASSWORD', ''), + 'charset' => 'utf8', + 'prefix' => '', + 'schema' => 'public', + 'sslmode' => 'prefer', ], 'travis' => [ diff --git a/config/mail.php b/config/mail.php index a0765885..1ed58486 100644 --- a/config/mail.php +++ b/config/mail.php @@ -54,8 +54,10 @@ return [ | used globally for all e-mails that are sent by your application. | */ - - 'from' => ['address' => null, 'name' => null], + 'from' => [ + 'address' => 'hello@example.com', + 'name' => 'Example', + ], /* |-------------------------------------------------------------------------- diff --git a/config/queue.php b/config/queue.php index b4ae7965..549322ed 100644 --- a/config/queue.php +++ b/config/queue.php @@ -11,7 +11,7 @@ return [ | API, giving you convenient access to each back-end using the same | syntax for each one. Here you may set the default queue driver. | - | Supported: "null", "sync", "database", "beanstalkd", "sqs", "redis" + | Supported: "sync", "database", "beanstalkd", "sqs", "redis", "null" | */ @@ -38,14 +38,14 @@ return [ 'driver' => 'database', 'table' => 'jobs', 'queue' => 'default', - 'expire' => 90, + 'retry_after' => 90, ], 'beanstalkd' => [ 'driver' => 'beanstalkd', 'host' => 'localhost', 'queue' => 'default', - 'ttr' => 90, + 'retry_after' => 90, ], 'sqs' => [ @@ -61,7 +61,7 @@ return [ 'driver' => 'redis', 'connection' => 'default', 'queue' => 'default', - 'expire' => 90, + 'retry_after' => 90, ], ], diff --git a/config/services.php b/config/services.php index 1581f1db..287b1186 100644 --- a/config/services.php +++ b/config/services.php @@ -19,10 +19,6 @@ return [ 'secret' => env('MAILGUN_SECRET'), ], - 'mandrill' => [ - 'secret' => env('MANDRILL_SECRET'), - ], - 'ses' => [ 'key' => env('SES_KEY'), 'secret' => env('SES_SECRET'), diff --git a/database/migrations/2016_09_06_152900_add_exception_column_to_failed_jobs_table.php b/database/migrations/2016_09_06_152900_add_exception_column_to_failed_jobs_table.php new file mode 100644 index 00000000..e42bce8b --- /dev/null +++ b/database/migrations/2016_09_06_152900_add_exception_column_to_failed_jobs_table.php @@ -0,0 +1,31 @@ +text('exception'); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::table('failed_jobs', function (Blueprint $table) { + $table->dropColumn('exception'); + }); + } +} diff --git a/routes/api.php b/routes/api.php new file mode 100644 index 00000000..6b907f39 --- /dev/null +++ b/routes/api.php @@ -0,0 +1,18 @@ +user(); +})->middleware('auth:api'); diff --git a/routes/console.php b/routes/console.php new file mode 100644 index 00000000..75dd0cde --- /dev/null +++ b/routes/console.php @@ -0,0 +1,18 @@ +comment(Inspiring::quote()); +})->describe('Display an inspiring quote'); diff --git a/app/Http/routes.php b/routes/web.php similarity index 96% rename from app/Http/routes.php rename to routes/web.php index 35f9fd42..da7a6f74 100644 --- a/app/Http/routes.php +++ b/routes/web.php @@ -2,12 +2,12 @@ /* |-------------------------------------------------------------------------- -| Application Routes +| Web Routes |-------------------------------------------------------------------------- | -| Here is where you can register all of the routes for an application. -| It's a breeze. Simply tell Laravel the URIs it should respond to -| and give it the controller to call when that URI is requested. +| This file is where you may define all of the routes that are handled +| by your application. Just tell Laravel the URIs it should respond +| to using a Closure or controller method. Build something great! | */