diff --git a/.editorconfig b/.editorconfig index 546affff..0dede531 100644 --- a/.editorconfig +++ b/.editorconfig @@ -5,17 +5,23 @@ root = true # Unix-style newlines with a newline ending every file [*] -end_of_line = lf charset = utf-8 +end_of_line = lf +indent_size = 4 +indent_style = space insert_final_newline = true trim_trailing_whitespace = true -indent_style = space -indent_size = 4 # Tab indentation [Makefile] indent_style = tab tab_width = 4 -[yml] +[*.md] +trim_trailing_whitespace = false + +[*.{yml,yaml}] indent_size = 2 + +[docker-compose.yml] +indent_size = 4 diff --git a/app/Console/Commands/MigratePlaceDataFromPostgis.php b/app/Console/Commands/MigratePlaceDataFromPostgis.php index 9ce93a27..8d5d2c92 100644 --- a/app/Console/Commands/MigratePlaceDataFromPostgis.php +++ b/app/Console/Commands/MigratePlaceDataFromPostgis.php @@ -25,22 +25,10 @@ class MigratePlaceDataFromPostgis extends Command */ protected $description = 'Copy Postgis data to normal latitude longitude fields'; - /** - * Create a new command instance. - * - * @return void - */ - public function __construct() - { - parent::__construct(); - } - /** * Execute the console command. - * - * @return int */ - public function handle() + public function handle(): int { $locationColumn = DB::selectOne(DB::raw(" SELECT EXISTS ( diff --git a/app/Console/Commands/ParseCachedWebMentions.php b/app/Console/Commands/ParseCachedWebMentions.php index a7c0b8ca..07a6c662 100644 --- a/app/Console/Commands/ParseCachedWebMentions.php +++ b/app/Console/Commands/ParseCachedWebMentions.php @@ -6,6 +6,7 @@ namespace App\Console\Commands; use App\Models\WebMention; use Illuminate\Console\Command; +use Illuminate\Contracts\Filesystem\FileNotFoundException; use Illuminate\FileSystem\FileSystem; class ParseCachedWebMentions extends Command @@ -27,9 +28,9 @@ class ParseCachedWebMentions extends Command /** * Execute the console command. * - * @return mixed + * @throws FileNotFoundException */ - public function handle(FileSystem $filesystem) + public function handle(FileSystem $filesystem): void { $htmlFiles = $filesystem->allFiles(storage_path() . '/HTML'); foreach ($htmlFiles as $file) { @@ -49,8 +50,6 @@ class ParseCachedWebMentions extends Command /** * Determine the source URL from a filename. - * - * @param string */ private function urlFromFilename(string $filepath): string { diff --git a/app/Console/Commands/ReDownloadWebMentions.php b/app/Console/Commands/ReDownloadWebMentions.php index 2c5c18e0..c6452ba9 100644 --- a/app/Console/Commands/ReDownloadWebMentions.php +++ b/app/Console/Commands/ReDownloadWebMentions.php @@ -24,22 +24,10 @@ class ReDownloadWebMentions extends Command */ protected $description = 'Redownload the HTML content of webmentions'; - /** - * Create a new command instance. - * - * @return void - */ - public function __construct() - { - parent::__construct(); - } - /** * Execute the console command. - * - * @return mixed */ - public function handle() + public function handle(): void { $webmentions = WebMention::all(); foreach ($webmentions as $webmention) { diff --git a/app/Console/Kernel.php b/app/Console/Kernel.php index 60f37be6..3ba67df6 100644 --- a/app/Console/Kernel.php +++ b/app/Console/Kernel.php @@ -10,7 +10,7 @@ class Kernel extends ConsoleKernel /** * The Artisan commands provided by your application. * - * @var array + * @var array */ protected $commands = [ Commands\ParseCachedWebMentions::class, @@ -20,21 +20,18 @@ class Kernel extends ConsoleKernel /** * Define the application's command schedule. * - * @return void - * * @codeCoverageIgnore */ - protected function schedule(Schedule $schedule) + protected function schedule(Schedule $schedule): void { $schedule->command('horizon:snapshot')->everyFiveMinutes(); + $schedule->command('cache:prune-stale-tags')->hourly(); } /** * Register the commands for the application. - * - * @return void */ - protected function commands() + protected function commands(): void { $this->load(__DIR__ . '/Commands'); diff --git a/app/Exceptions/Handler.php b/app/Exceptions/Handler.php index 30e8b3e1..1595d484 100644 --- a/app/Exceptions/Handler.php +++ b/app/Exceptions/Handler.php @@ -21,46 +21,34 @@ class Handler extends ExceptionHandler /** * A list of the exception types that are not reported. * - * @var array + * @var array> */ protected $dontReport = [ NotFoundHttpException::class, ModelNotFoundException::class, ]; - /** - * A list of the inputs that are never flashed for validation exceptions. - * - * @var array - */ - protected $dontFlash = [ - 'password', - 'password_confirmation', - ]; - /** * Report or log an exception. * * This is a great spot to send exceptions to Sentry, Bugsnag, etc. * - * @return void - * * @throws Exception * @throws Throwable */ - public function report(Throwable $throwable) + public function report(Throwable $e): void { - parent::report($throwable); + parent::report($e); - if (config('logging.slack') && $this->shouldReport($throwable)) { + if (config('logging.slack') && $this->shouldReport($e)) { $guzzle = new Client([ 'headers' => [ 'Content-Type' => 'application/json', ], ]); - $exceptionName = get_class($throwable) ?? 'Unknown Exception'; - $title = $exceptionName . ': ' . $throwable->getMessage(); + $exceptionName = get_class($e) ?? 'Unknown Exception'; + $title = $exceptionName . ': ' . $e->getMessage(); $guzzle->post( config('logging.slack'), diff --git a/app/Http/Controllers/ArticlesController.php b/app/Http/Controllers/ArticlesController.php index 5ca8a907..6ea4d1ed 100644 --- a/app/Http/Controllers/ArticlesController.php +++ b/app/Http/Controllers/ArticlesController.php @@ -27,10 +27,8 @@ class ArticlesController extends Controller /** * Show a single article. - * - * @return RedirectResponse|View */ - public function show(int $year, int $month, string $slug) + public function show(int $year, int $month, string $slug): RedirectResponse|View { try { $article = Article::where('titleurl', $slug)->firstOrFail(); @@ -49,8 +47,7 @@ class ArticlesController extends Controller } /** - * We only have the ID, work out post title, year and month - * and redirect to it. + * We only have the ID, work out post title, year and month and redirect to it. */ public function onlyIdInUrl(string $idFromUrl): RedirectResponse { diff --git a/app/Http/Controllers/AuthController.php b/app/Http/Controllers/AuthController.php index 01d91602..a37ce8fb 100644 --- a/app/Http/Controllers/AuthController.php +++ b/app/Http/Controllers/AuthController.php @@ -5,6 +5,7 @@ declare(strict_types=1); namespace App\Http\Controllers; use Illuminate\Http\RedirectResponse; +use Illuminate\Http\Request; use Illuminate\Support\Facades\Auth; use Illuminate\View\View; @@ -12,10 +13,8 @@ class AuthController extends Controller { /** * Show the login form. - * - * @return View|RedirectResponse */ - public function showLogin() + public function showLogin(): View|RedirectResponse { if (Auth::check()) { return redirect('/'); @@ -25,12 +24,11 @@ class AuthController extends Controller } /** - * Log in a user, set a session variable, check credentials against - * the .env file. + * Log in a user, set a session variable, check credentials against the `.env` file. */ - public function login(): RedirectResponse + public function login(Request $request): RedirectResponse { - $credentials = request()->only('name', 'password'); + $credentials = $request->only('name', 'password'); if (Auth::attempt($credentials, true)) { return redirect()->intended('/'); @@ -40,11 +38,9 @@ class AuthController extends Controller } /** - * Show the form to logout a user. - * - * @return View|RedirectResponse + * Show the form to allow a user to log-out. */ - public function showLogout() + public function showLogout(): View|RedirectResponse { if (Auth::check() === false) { // The user is not logged in, just redirect them home @@ -56,8 +52,6 @@ class AuthController extends Controller /** * Log the user out from their current session. - * - * @return RedirectResponse; */ public function logout(): RedirectResponse { diff --git a/app/Http/Controllers/FeedsController.php b/app/Http/Controllers/FeedsController.php index 16db9bfa..08c9a3ae 100644 --- a/app/Http/Controllers/FeedsController.php +++ b/app/Http/Controllers/FeedsController.php @@ -96,10 +96,8 @@ class FeedsController extends Controller /** * Returns the notes JSON feed. - * - * @return array */ - public function notesJson() + public function notesJson(): array { $notes = Note::latest()->with('media')->take(20)->get(); $data = [ diff --git a/app/Http/Controllers/FrontPageController.php b/app/Http/Controllers/FrontPageController.php index bcf82af4..9d37c9db 100644 --- a/app/Http/Controllers/FrontPageController.php +++ b/app/Http/Controllers/FrontPageController.php @@ -7,6 +7,7 @@ use App\Models\Bookmark; use App\Models\Like; use App\Models\Note; use App\Services\ActivityStreamsService; +use Illuminate\Http\Request; use Illuminate\Http\Response; use Illuminate\View\View; @@ -14,12 +15,10 @@ class FrontPageController extends Controller { /** * Show all the recent activity. - * - * @return Response|View */ - public function index() + public function index(Request $request): Response|View { - if (request()->wantsActivityStream()) { + if ($request->wantsActivityStream()) { return (new ActivityStreamsService())->siteOwnerResponse(); } diff --git a/app/Http/Controllers/MicropubController.php b/app/Http/Controllers/MicropubController.php index a667b560..1d1eccc3 100644 --- a/app/Http/Controllers/MicropubController.php +++ b/app/Http/Controllers/MicropubController.php @@ -115,34 +115,34 @@ class MicropubController extends Controller * appropriately. Further if the request has the query parameter * syndicate-to we respond with the known syndication endpoints. */ - public function get(): JsonResponse + public function get(Request $request): JsonResponse { try { - $tokenData = $this->tokenService->validateToken(request()->input('access_token')); + $tokenData = $this->tokenService->validateToken($request->input('access_token')); } catch (RequiredConstraintsViolated|InvalidTokenStructure) { return (new MicropubResponses())->invalidTokenResponse(); } - if (request()->input('q') === 'syndicate-to') { + if ($request->input('q') === 'syndicate-to') { return response()->json([ 'syndicate-to' => SyndicationTarget::all(), ]); } - if (request()->input('q') === 'config') { + if ($request->input('q') === 'config') { return response()->json([ 'syndicate-to' => SyndicationTarget::all(), 'media-endpoint' => route('media-endpoint'), ]); } - if (request()->has('q') && substr(request()->input('q'), 0, 4) === 'geo:') { + if ($request->has('q') && str_starts_with($request->input('q'), 'geo:')) { preg_match_all( '/([0-9.\-]+)/', - request()->input('q'), + $request->input('q'), $matches ); - $distance = (count($matches[0]) == 3) ? 100 * $matches[0][2] : 1000; + $distance = (count($matches[0]) === 3) ? 100 * $matches[0][2] : 1000; $places = Place::near( (object) ['latitude' => $matches[0][0], 'longitude' => $matches[0][1]], $distance @@ -168,22 +168,19 @@ class MicropubController extends Controller /** * Determine the client id from the access token sent with the request. * - * * @throws RequiredConstraintsViolated */ private function getClientId(): string { return resolve(TokenService::class) - ->validateToken(request()->input('access_token')) + ->validateToken(app('request')->input('access_token')) ->claims()->get('client_id'); } /** * Save the details of the micropub request to a log file. - * - * @param array $request This is the info from request()->all() */ - private function logMicropubRequest(array $request) + private function logMicropubRequest(array $request): void { $logger = new Logger('micropub'); $logger->pushHandler(new StreamHandler(storage_path('logs/micropub.log'))); diff --git a/app/Http/Controllers/MicropubMediaController.php b/app/Http/Controllers/MicropubMediaController.php index f79928dd..acd8ad0d 100644 --- a/app/Http/Controllers/MicropubMediaController.php +++ b/app/Http/Controllers/MicropubMediaController.php @@ -98,14 +98,13 @@ class MicropubMediaController extends Controller /** * Process a media item posted to the media endpoint. * - * * @throws BindingResolutionException * @throws Exception */ - public function media(): JsonResponse + public function media(Request $request): JsonResponse { try { - $tokenData = $this->tokenService->validateToken(request()->input('access_token')); + $tokenData = $this->tokenService->validateToken($request->input('access_token')); } catch (RequiredConstraintsViolated|InvalidTokenStructure $exception) { $micropubResponses = new MicropubResponses(); @@ -124,7 +123,7 @@ class MicropubMediaController extends Controller return $micropubResponses->insufficientScopeResponse(); } - if (request()->hasFile('file') === false) { + if ($request->hasFile('file') === false) { return response()->json([ 'response' => 'error', 'error' => 'invalid_request', @@ -132,7 +131,7 @@ class MicropubMediaController extends Controller ], 400); } - if (request()->file('file')->isValid() === false) { + if ($request->file('file')->isValid() === false) { return response()->json([ 'response' => 'error', 'error' => 'invalid_request', @@ -140,11 +139,11 @@ class MicropubMediaController extends Controller ], 400); } - $filename = $this->saveFile(request()->file('file')); + $filename = $this->saveFile($request->file('file')); $manager = resolve(ImageManager::class); try { - $image = $manager->make(request()->file('file')); + $image = $manager->make($request->file('file')); $width = $image->width(); } catch (NotReadableException $exception) { // not an image @@ -152,9 +151,9 @@ class MicropubMediaController extends Controller } $media = Media::create([ - 'token' => request()->bearerToken(), + 'token' => $request->bearerToken(), 'path' => 'media/' . $filename, - 'type' => $this->getFileTypeFromMimeType(request()->file('file')->getMimeType()), + 'type' => $this->getFileTypeFromMimeType($request->file('file')->getMimeType()), 'image_widths' => $width, ]); @@ -226,7 +225,6 @@ class MicropubMediaController extends Controller /** * Save an uploaded file to the local disk. * - * * @throws Exception */ private function saveFile(UploadedFile $file): string diff --git a/app/Http/Controllers/NotesController.php b/app/Http/Controllers/NotesController.php index 543b6158..aea2bd76 100644 --- a/app/Http/Controllers/NotesController.php +++ b/app/Http/Controllers/NotesController.php @@ -9,6 +9,7 @@ use App\Services\ActivityStreamsService; use Illuminate\Database\Eloquent\ModelNotFoundException; use Illuminate\Http\JsonResponse; use Illuminate\Http\RedirectResponse; +use Illuminate\Http\Request; use Illuminate\Http\Response; use Illuminate\View\View; use Jonnybarnes\IndieWeb\Numbers; @@ -19,12 +20,10 @@ class NotesController extends Controller { /** * Show all the notes. This is also the homepage. - * - * @return View|Response */ - public function index() + public function index(Request $request): View|Response { - if (request()->wantsActivityStream()) { + if ($request->wantsActivityStream()) { return (new ActivityStreamsService())->siteOwnerResponse(); } @@ -39,11 +38,8 @@ class NotesController extends Controller /** * Show a single note. - * - * @param string $urlId The id of the note - * @return View|JsonResponse|Response */ - public function show(string $urlId) + public function show(string $urlId): View|JsonResponse|Response { try { $note = Note::nb60($urlId)->with('webmentions')->firstOrFail(); @@ -60,8 +56,6 @@ class NotesController extends Controller /** * Redirect /note/{decID} to /notes/{nb60id}. - * - * @param int $decId The decimal id of the note */ public function redirect(int $decId): RedirectResponse { diff --git a/app/Http/Controllers/ShortURLsController.php b/app/Http/Controllers/ShortURLsController.php index 440d79f7..ae8128f0 100644 --- a/app/Http/Controllers/ShortURLsController.php +++ b/app/Http/Controllers/ShortURLsController.php @@ -35,17 +35,15 @@ class ShortURLsController extends Controller /** * Redirect a short url of this site out to a long one based on post type. - * Further redirects may happen. * - * @param string Post type - * @param string Post ID + * Further redirects may happen. */ public function expandType(string $type, string $postId): RedirectResponse { - if ($type == 't') { + if ($type === 't') { $type = 'notes'; } - if ($type == 'b') { + if ($type === 'b') { $type = 'blog/s'; } diff --git a/app/Http/Controllers/TokenEndpointController.php b/app/Http/Controllers/TokenEndpointController.php index 06fa15df..73e86deb 100644 --- a/app/Http/Controllers/TokenEndpointController.php +++ b/app/Http/Controllers/TokenEndpointController.php @@ -24,9 +24,6 @@ class TokenEndpointController extends Controller */ protected GuzzleClient $guzzle; - /** - * @var TokenService The Token handling service. - */ protected TokenService $tokenService; /** diff --git a/app/Http/Controllers/WebMentionsController.php b/app/Http/Controllers/WebMentionsController.php index f5626742..b6c4a71b 100644 --- a/app/Http/Controllers/WebMentionsController.php +++ b/app/Http/Controllers/WebMentionsController.php @@ -7,6 +7,7 @@ namespace App\Http\Controllers; use App\Jobs\ProcessWebMention; use App\Models\Note; use Illuminate\Database\Eloquent\ModelNotFoundException; +use Illuminate\Http\Request; use Illuminate\Http\Response; use Illuminate\View\View; use Jonnybarnes\IndieWeb\Numbers; @@ -27,10 +28,10 @@ class WebMentionsController extends Controller /** * Receive and process a webmention. */ - public function receive(): Response + public function receive(Request $request): Response { //first we trivially reject requests that lack all required inputs - if ((request()->has('target') !== true) || (request()->has('source') !== true)) { + if (($request->has('target') !== true) || ($request->has('source') !== true)) { return response( 'You need both the target and source parameters', 400 @@ -38,15 +39,15 @@ class WebMentionsController extends Controller } //next check the $target is valid - $path = parse_url(request()->input('target'), PHP_URL_PATH); + $path = parse_url($request->input('target'), PHP_URL_PATH); $pathParts = explode('/', $path); - if ($pathParts[1] == 'notes') { + if ($pathParts[1] === 'notes') { //we have a note $noteId = $pathParts[2]; try { $note = Note::findOrFail(resolve(Numbers::class)->b60tonum($noteId)); - dispatch(new ProcessWebMention($note, request()->input('source'))); + dispatch(new ProcessWebMention($note, $request->input('source'))); } catch (ModelNotFoundException $e) { return response('This note doesn’t exist.', 400); } @@ -56,7 +57,7 @@ class WebMentionsController extends Controller 202 ); } - if ($pathParts[1] == 'blog') { + if ($pathParts[1] === 'blog') { return response( 'I don’t accept webmentions for blog posts yet.', 501 diff --git a/app/Http/Kernel.php b/app/Http/Kernel.php index 5da917fc..d2be1cb7 100644 --- a/app/Http/Kernel.php +++ b/app/Http/Kernel.php @@ -11,7 +11,7 @@ class Kernel extends HttpKernel * * These middleware are run during every request to your application. * - * @var array + * @var array */ protected $middleware = [ // \App\Http\Middleware\TrustHosts::class, @@ -26,7 +26,7 @@ class Kernel extends HttpKernel /** * The application's route middleware groups. * - * @var array + * @var array> */ protected $middlewareGroups = [ 'web' => [ @@ -44,21 +44,23 @@ class Kernel extends HttpKernel ], 'api' => [ - 'throttle:api', + // \Laravel\Sanctum\Http\Middleware\EnsureFrontendRequestsAreStateful::class, + \Illuminate\Routing\Middleware\ThrottleRequests::class.':api', \Illuminate\Routing\Middleware\SubstituteBindings::class, ], ]; /** - * The application's route middleware. + * The application's middleware aliases. * - * These middleware may be assigned to groups or used individually. + * Aliases may be used to conveniently assign middleware to routes and groups. * - * @var array + * @var array */ - protected $routeMiddleware = [ + protected $middlewareAliases = [ 'auth' => \App\Http\Middleware\Authenticate::class, 'auth.basic' => \Illuminate\Auth\Middleware\AuthenticateWithBasicAuth::class, + 'auth.session' => \Illuminate\Session\Middleware\AuthenticateSession::class, 'cache.headers' => \Illuminate\Http\Middleware\SetCacheHeaders::class, 'can' => \Illuminate\Auth\Middleware\Authorize::class, 'guest' => \App\Http\Middleware\RedirectIfAuthenticated::class, diff --git a/app/Http/Middleware/ActivityStreamLinks.php b/app/Http/Middleware/ActivityStreamLinks.php index 298865b4..47727d98 100644 --- a/app/Http/Middleware/ActivityStreamLinks.php +++ b/app/Http/Middleware/ActivityStreamLinks.php @@ -6,15 +6,14 @@ namespace App\Http\Middleware; use Closure; use Illuminate\Http\Request; +use Symfony\Component\HttpFoundation\Response; class ActivityStreamLinks { /** * Handle an incoming request. - * - * @return mixed */ - public function handle(Request $request, Closure $next) + public function handle(Request $request, Closure $next): Response { $response = $next($request); if ($request->path() === '/') { diff --git a/app/Http/Middleware/Authenticate.php b/app/Http/Middleware/Authenticate.php index 81e6fd40..624cd371 100644 --- a/app/Http/Middleware/Authenticate.php +++ b/app/Http/Middleware/Authenticate.php @@ -3,6 +3,7 @@ namespace App\Http\Middleware; use Illuminate\Auth\Middleware\Authenticate as Middleware; +use Illuminate\Http\Request; /** * @codeCoverageIgnore @@ -11,14 +12,9 @@ class Authenticate extends Middleware { /** * Get the path the user should be redirected to when they are not authenticated. - * - * @param \Illuminate\Http\Request $request - * @return string */ - protected function redirectTo($request) + protected function redirectTo(Request $request): ?string { - if (! $request->expectsJson()) { - return route('login'); - } + return $request->expectsJson() ? null : route('login'); } } diff --git a/app/Http/Middleware/CSPHeader.php b/app/Http/Middleware/CSPHeader.php index 0e8a9d87..07e77e3a 100644 --- a/app/Http/Middleware/CSPHeader.php +++ b/app/Http/Middleware/CSPHeader.php @@ -5,16 +5,14 @@ namespace App\Http\Middleware; use Closure; use Illuminate\Http\Request; use Illuminate\Support\Facades\App; +use Symfony\Component\HttpFoundation\Response; class CSPHeader { /** * Handle an incoming request. - * - * @param Request $request - * @return mixed */ - public function handle($request, Closure $next) + public function handle(Request $request, Closure $next): Response { if (App::environment('local', 'development')) { return $next($request); diff --git a/app/Http/Middleware/CheckForMaintenanceMode.php b/app/Http/Middleware/CheckForMaintenanceMode.php deleted file mode 100644 index 35b9824b..00000000 --- a/app/Http/Middleware/CheckForMaintenanceMode.php +++ /dev/null @@ -1,17 +0,0 @@ -path() === 'api/media') { diff --git a/app/Http/Middleware/EncryptCookies.php b/app/Http/Middleware/EncryptCookies.php index 033136ad..867695bd 100644 --- a/app/Http/Middleware/EncryptCookies.php +++ b/app/Http/Middleware/EncryptCookies.php @@ -9,7 +9,7 @@ class EncryptCookies extends Middleware /** * The names of the cookies that should not be encrypted. * - * @var array + * @var array */ protected $except = [ // diff --git a/app/Http/Middleware/LinkHeadersMiddleware.php b/app/Http/Middleware/LinkHeadersMiddleware.php index bb0422f7..d2a1b4f6 100644 --- a/app/Http/Middleware/LinkHeadersMiddleware.php +++ b/app/Http/Middleware/LinkHeadersMiddleware.php @@ -3,16 +3,15 @@ namespace App\Http\Middleware; use Closure; +use Illuminate\Http\Request; +use Symfony\Component\HttpFoundation\Response; class LinkHeadersMiddleware { /** * Handle an incoming request. - * - * @param \Illuminate\Http\Request $request - * @return mixed */ - public function handle($request, Closure $next) + public function handle(Request $request, Closure $next): Response { $response = $next($request); $response->header('Link', '; rel="authorization_endpoint"', false); diff --git a/app/Http/Middleware/LocalhostSessionMiddleware.php b/app/Http/Middleware/LocalhostSessionMiddleware.php index a8e84455..060682d5 100644 --- a/app/Http/Middleware/LocalhostSessionMiddleware.php +++ b/app/Http/Middleware/LocalhostSessionMiddleware.php @@ -6,6 +6,7 @@ namespace App\Http\Middleware; use Closure; use Illuminate\Http\Request; +use Symfony\Component\HttpFoundation\Response; class LocalhostSessionMiddleware { @@ -13,10 +14,8 @@ class LocalhostSessionMiddleware * Whilst we are developing locally, automatically log in as * `['me' => config('app.url')]` as I can’t manually log in as * a .localhost domain. - * - * @return mixed */ - public function handle(Request $request, Closure $next) + public function handle(Request $request, Closure $next): Response { if (config('app.env') !== 'production') { session(['me' => config('app.url')]); diff --git a/app/Http/Middleware/MyAuthMiddleware.php b/app/Http/Middleware/MyAuthMiddleware.php index c4f9da6f..57d0bfa3 100644 --- a/app/Http/Middleware/MyAuthMiddleware.php +++ b/app/Http/Middleware/MyAuthMiddleware.php @@ -7,18 +7,17 @@ namespace App\Http\Middleware; use Closure; use Illuminate\Http\Request; use Illuminate\Support\Facades\Auth; +use Symfony\Component\HttpFoundation\Response; class MyAuthMiddleware { /** * Check the user is logged in. - * - * @return mixed */ - public function handle(Request $request, Closure $next) + public function handle(Request $request, Closure $next): Response { - if (Auth::check($request->user()) == false) { - //they’re not logged in, so send them to login form + if (Auth::check() === false) { + // they’re not logged in, so send them to login form return redirect()->route('login'); } diff --git a/app/Http/Middleware/PreventRequestsDuringMaintenance.php b/app/Http/Middleware/PreventRequestsDuringMaintenance.php index e4956d0b..74cbd9a9 100644 --- a/app/Http/Middleware/PreventRequestsDuringMaintenance.php +++ b/app/Http/Middleware/PreventRequestsDuringMaintenance.php @@ -9,7 +9,7 @@ class PreventRequestsDuringMaintenance extends Middleware /** * The URIs that should be reachable while maintenance mode is enabled. * - * @var array + * @var array */ protected $except = [ // diff --git a/app/Http/Middleware/RedirectIfAuthenticated.php b/app/Http/Middleware/RedirectIfAuthenticated.php index f15a8dab..a6a6c8c4 100644 --- a/app/Http/Middleware/RedirectIfAuthenticated.php +++ b/app/Http/Middleware/RedirectIfAuthenticated.php @@ -6,6 +6,7 @@ use App\Providers\RouteServiceProvider; use Closure; use Illuminate\Http\Request; use Illuminate\Support\Facades\Auth; +use Symfony\Component\HttpFoundation\Response; /** * @codeCoverageIgnore @@ -15,10 +16,9 @@ class RedirectIfAuthenticated /** * Handle an incoming request. * - * @param string|null ...$guards - * @return mixed + * @param \Closure(\Illuminate\Http\Request): (\Symfony\Component\HttpFoundation\Response) $next */ - public function handle(Request $request, Closure $next, ...$guards) + public function handle(Request $request, Closure $next, string ...$guards): Response { $guards = empty($guards) ? [null] : $guards; diff --git a/app/Http/Middleware/TrimStrings.php b/app/Http/Middleware/TrimStrings.php index 5a50e7b5..88cadcaa 100644 --- a/app/Http/Middleware/TrimStrings.php +++ b/app/Http/Middleware/TrimStrings.php @@ -9,9 +9,10 @@ class TrimStrings extends Middleware /** * The names of the attributes that should not be trimmed. * - * @var array + * @var array */ protected $except = [ + 'current_password', 'password', 'password_confirmation', ]; diff --git a/app/Http/Middleware/TrustHosts.php b/app/Http/Middleware/TrustHosts.php index 79426404..9c88c34c 100644 --- a/app/Http/Middleware/TrustHosts.php +++ b/app/Http/Middleware/TrustHosts.php @@ -12,9 +12,9 @@ class TrustHosts extends Middleware /** * Get the host patterns that should be trusted. * - * @return array + * @return array */ - public function hosts() + public function hosts(): array { return [ $this->allSubdomainsOfApplicationUrl(), diff --git a/app/Http/Middleware/TrustProxies.php b/app/Http/Middleware/TrustProxies.php index d5563e69..f33f3eef 100644 --- a/app/Http/Middleware/TrustProxies.php +++ b/app/Http/Middleware/TrustProxies.php @@ -10,7 +10,7 @@ class TrustProxies extends Middleware /** * The trusted proxies for this application. * - * @var array|string + * @var array|string|null */ protected $proxies; diff --git a/app/Http/Middleware/VerifyCsrfToken.php b/app/Http/Middleware/VerifyCsrfToken.php index 1593e373..fc7bad50 100644 --- a/app/Http/Middleware/VerifyCsrfToken.php +++ b/app/Http/Middleware/VerifyCsrfToken.php @@ -9,7 +9,7 @@ class VerifyCsrfToken extends Middleware /** * The URIs that should be excluded from CSRF verification. * - * @var array + * @var array */ protected $except = [ 'api/media', diff --git a/app/Http/Middleware/VerifyMicropubToken.php b/app/Http/Middleware/VerifyMicropubToken.php index b868239e..813350cf 100644 --- a/app/Http/Middleware/VerifyMicropubToken.php +++ b/app/Http/Middleware/VerifyMicropubToken.php @@ -6,15 +6,14 @@ namespace App\Http\Middleware; use Closure; use Illuminate\Http\Request; +use Symfony\Component\HttpFoundation\Response; class VerifyMicropubToken { /** * Handle an incoming request. - * - * @return mixed */ - public function handle(Request $request, Closure $next) + public function handle(Request $request, Closure $next): Response { if ($request->input('access_token')) { return $next($request); diff --git a/app/Jobs/AddClientToDatabase.php b/app/Jobs/AddClientToDatabase.php index de3d12ee..b540aac0 100644 --- a/app/Jobs/AddClientToDatabase.php +++ b/app/Jobs/AddClientToDatabase.php @@ -18,24 +18,22 @@ class AddClientToDatabase implements ShouldQueue use Queueable; use SerializesModels; - protected $client_id; + protected string $client_id; /** * Create a new job instance. */ - public function __construct(string $client_id) + public function __construct(string $clientId) { - $this->client_id = $client_id; + $this->client_id = $clientId; } /** * Execute the job. - * - * @return void */ - public function handle() + public function handle(): void { - if (MicropubClient::where('client_url', $this->client_id)->count() == 0) { + if (MicropubClient::where('client_url', $this->client_id)->count() === 0) { MicropubClient::create([ 'client_url' => $this->client_id, 'client_name' => $this->client_id, // default client name is the URL diff --git a/app/Jobs/DownloadWebMention.php b/app/Jobs/DownloadWebMention.php index ff2342d2..72f469e5 100644 --- a/app/Jobs/DownloadWebMention.php +++ b/app/Jobs/DownloadWebMention.php @@ -19,34 +19,26 @@ class DownloadWebMention implements ShouldQueue use Queueable; use SerializesModels; - /** - * The webmention source URL. - * - * @var string - */ - protected $source; - /** * Create a new job instance. */ - public function __construct(string $source) - { - $this->source = $source; + public function __construct( + protected string $source + ) { } /** * Execute the job. * - * * @throws GuzzleException * @throws FileNotFoundException */ - public function handle(Client $guzzle) + public function handle(Client $guzzle): void { $response = $guzzle->request('GET', $this->source); //4XX and 5XX responses should get Guzzle to throw an exception, //Laravel should catch and retry these automatically. - if ($response->getStatusCode() == '200') { + if ($response->getStatusCode() === 200) { $filesystem = new FileSystem(); $filename = storage_path('HTML') . '/' . $this->createFilenameFromURL($this->source); //backup file first @@ -69,7 +61,7 @@ class DownloadWebMention implements ShouldQueue ); //remove backup if the same if ($filesystem->exists($filenameBackup)) { - if ($filesystem->get($filename) == $filesystem->get($filenameBackup)) { + if ($filesystem->get($filename) === $filesystem->get($filenameBackup)) { $filesystem->delete($filenameBackup); } } @@ -78,13 +70,11 @@ class DownloadWebMention implements ShouldQueue /** * Create a file path from a URL. This is used when caching the HTML response. - * - * @return string The path name */ - private function createFilenameFromURL(string $url) + private function createFilenameFromURL(string $url): string { $filepath = str_replace(['https://', 'http://'], ['https/', 'http/'], $url); - if (substr($filepath, -1) == '/') { + if (str_ends_with($filepath, '/')) { $filepath .= 'index.html'; } diff --git a/app/Jobs/ProcessBookmark.php b/app/Jobs/ProcessBookmark.php index cdbca8a2..b1dffe8a 100644 --- a/app/Jobs/ProcessBookmark.php +++ b/app/Jobs/ProcessBookmark.php @@ -20,14 +20,12 @@ class ProcessBookmark implements ShouldQueue use Queueable; use SerializesModels; - protected Bookmark $bookmark; - /** * Create a new job instance. */ - public function __construct(Bookmark $bookmark) - { - $this->bookmark = $bookmark; + public function __construct( + protected Bookmark $bookmark + ) { } /** diff --git a/app/Jobs/ProcessLike.php b/app/Jobs/ProcessLike.php index cafe156d..3a2d6f62 100644 --- a/app/Jobs/ProcessLike.php +++ b/app/Jobs/ProcessLike.php @@ -25,21 +25,17 @@ class ProcessLike implements ShouldQueue use Queueable; use SerializesModels; - /** @var Like */ - protected $like; - /** * Create a new job instance. */ - public function __construct(Like $like) - { - $this->like = $like; + public function __construct( + protected Like $like + ) { } /** * Execute the job. * - * * @throws GuzzleException */ public function handle(Client $client, Authorship $authorship): int diff --git a/app/Jobs/ProcessMedia.php b/app/Jobs/ProcessMedia.php index 8ce127b0..f35bdd1a 100644 --- a/app/Jobs/ProcessMedia.php +++ b/app/Jobs/ProcessMedia.php @@ -20,21 +20,18 @@ class ProcessMedia implements ShouldQueue use Queueable; use SerializesModels; - /** @var string */ - protected $filename; - /** * Create a new job instance. */ - public function __construct(string $filename) - { - $this->filename = $filename; + public function __construct( + protected string $filename + ) { } /** * Execute the job. */ - public function handle(ImageManager $manager) + public function handle(ImageManager $manager): void { //open file try { diff --git a/app/Jobs/ProcessWebMention.php b/app/Jobs/ProcessWebMention.php index 55f35b75..6aacf29d 100644 --- a/app/Jobs/ProcessWebMention.php +++ b/app/Jobs/ProcessWebMention.php @@ -24,30 +24,23 @@ class ProcessWebMention implements ShouldQueue use Queueable; use SerializesModels; - /** @var Note */ - protected $note; - - /** @var string */ - protected $source; - /** * Create a new job instance. */ - public function __construct(Note $note, string $source) - { - $this->note = $note; - $this->source = $source; + public function __construct( + protected Note $note, + protected string $source + ) { } /** * Execute the job. * - * * @throws RemoteContentNotFoundException * @throws GuzzleException * @throws InvalidMentionException */ - public function handle(Parser $parser, Client $guzzle) + public function handle(Parser $parser, Client $guzzle): void { try { $response = $guzzle->request('GET', $this->source); @@ -60,8 +53,8 @@ class ProcessWebMention implements ShouldQueue foreach ($webmentions as $webmention) { // check webmention still references target // we try each type of mention (reply/like/repost) - if ($webmention->type == 'in-reply-to') { - if ($parser->checkInReplyTo($microformats, $this->note->longurl) == false) { + if ($webmention->type === 'in-reply-to') { + if ($parser->checkInReplyTo($microformats, $this->note->longurl) === false) { // it doesn’t so delete $webmention->delete(); @@ -74,16 +67,16 @@ class ProcessWebMention implements ShouldQueue return; } - if ($webmention->type == 'like-of') { - if ($parser->checkLikeOf($microformats, $this->note->longurl) == false) { + if ($webmention->type === 'like-of') { + if ($parser->checkLikeOf($microformats, $this->note->longurl) === false) { // it doesn’t so delete $webmention->delete(); return; } // note we don’t need to do anything if it still is a like } - if ($webmention->type == 'repost-of') { - if ($parser->checkRepostOf($microformats, $this->note->longurl) == false) { + if ($webmention->type === 'repost-of') { + if ($parser->checkRepostOf($microformats, $this->note->longurl) === false) { // it doesn’t so delete $webmention->delete(); @@ -107,26 +100,23 @@ class ProcessWebMention implements ShouldQueue /** * Save the HTML of a webmention for future use. - * - * @param string $html - * @param string $url */ - private function saveRemoteContent($html, $url) + private function saveRemoteContent(string $html, string $url): void { $filenameFromURL = str_replace( ['https://', 'http://'], ['https/', 'http/'], $url ); - if (substr($url, -1) == '/') { + if (str_ends_with($url, '/')) { $filenameFromURL .= 'index.html'; } $path = storage_path() . '/HTML/' . $filenameFromURL; $parts = explode('/', $path); $name = array_pop($parts); $dir = implode('/', $parts); - if (! is_dir($dir)) { - mkdir($dir, 0755, true); + if (! is_dir($dir) && ! mkdir($dir, 0755, true) && ! is_dir($dir)) { + throw new \RuntimeException(sprintf('Directory "%s" was not created', $dir)); } file_put_contents("$dir/$name", $html); } diff --git a/app/Jobs/SaveProfileImage.php b/app/Jobs/SaveProfileImage.php index 8535d8c9..4183d587 100644 --- a/app/Jobs/SaveProfileImage.php +++ b/app/Jobs/SaveProfileImage.php @@ -20,25 +20,23 @@ class SaveProfileImage implements ShouldQueue use Queueable; use SerializesModels; - protected array $microformats; - /** * Create a new job instance. */ - public function __construct(array $microformats) - { - $this->microformats = $microformats; + public function __construct( + protected array $microformats + ) { } /** * Execute the job. */ - public function handle(Authorship $authorship) + public function handle(Authorship $authorship): void { try { $author = $authorship->findAuthor($this->microformats); } catch (AuthorshipParserException) { - return null; + return; } $photo = Arr::get($author, 'properties.photo.0'); @@ -47,8 +45,8 @@ class SaveProfileImage implements ShouldQueue //dont save pbs.twimg.com links if ( $photo - && parse_url($photo, PHP_URL_HOST) != 'pbs.twimg.com' - && parse_url($photo, PHP_URL_HOST) != 'twitter.com' + && parse_url($photo, PHP_URL_HOST) !== 'pbs.twimg.com' + && parse_url($photo, PHP_URL_HOST) !== 'twitter.com' ) { $client = resolve(Client::class); @@ -67,8 +65,8 @@ class SaveProfileImage implements ShouldQueue $parts = explode('/', $path); $name = array_pop($parts); $dir = implode('/', $parts); - if (! is_dir($dir)) { - mkdir($dir, 0755, true); + if (! is_dir($dir) && ! mkdir($dir, 0755, true) && ! is_dir($dir)) { + throw new \RuntimeException(sprintf('Directory "%s" was not created', $dir)); } file_put_contents("$dir/$name", $image); } diff --git a/app/Jobs/SaveScreenshot.php b/app/Jobs/SaveScreenshot.php index 74e37305..c086276c 100755 --- a/app/Jobs/SaveScreenshot.php +++ b/app/Jobs/SaveScreenshot.php @@ -18,16 +18,12 @@ class SaveScreenshot implements ShouldQueue { use Dispatchable, InteractsWithQueue, Queueable, SerializesModels; - private Bookmark $bookmark; - /** * Create a new job instance. - * - * @return void */ - public function __construct(Bookmark $bookmark) - { - $this->bookmark = $bookmark; + public function __construct( + protected Bookmark $bookmark + ) { } /** diff --git a/app/Jobs/SendWebMentions.php b/app/Jobs/SendWebMentions.php index 153c33ee..b481f69d 100644 --- a/app/Jobs/SendWebMentions.php +++ b/app/Jobs/SendWebMentions.php @@ -22,20 +22,17 @@ class SendWebMentions implements ShouldQueue use Queueable; use SerializesModels; - protected Note $note; - /** - * Create the job instance, inject dependencies. + * Create a new job instance. */ - public function __construct(Note $note) - { - $this->note = $note; + public function __construct( + protected Note $note + ) { } /** * Execute the job. * - * * @throws GuzzleException */ public function handle(): void @@ -60,7 +57,6 @@ class SendWebMentions implements ShouldQueue /** * Discover if a URL has a webmention endpoint. * - * * @throws GuzzleException */ public function discoverWebmentionEndpoint(string $url): ?string @@ -126,8 +122,6 @@ class SendWebMentions implements ShouldQueue /** * Resolve a URI if necessary. - * - * @param string $base The base of the URL */ public function resolveUri(string $url, string $base): string { diff --git a/app/Jobs/SyndicateBookmarkToTwitter.php b/app/Jobs/SyndicateBookmarkToTwitter.php index d919e0b1..3aaac492 100644 --- a/app/Jobs/SyndicateBookmarkToTwitter.php +++ b/app/Jobs/SyndicateBookmarkToTwitter.php @@ -20,24 +20,20 @@ class SyndicateBookmarkToTwitter implements ShouldQueue use Queueable; use SerializesModels; - /** @var Bookmark */ - protected $bookmark; - /** * Create a new job instance. */ - public function __construct(Bookmark $bookmark) - { - $this->bookmark = $bookmark; + public function __construct( + protected Bookmark $bookmark + ) { } /** * Execute the job. * - * * @throws GuzzleException */ - public function handle(Client $guzzle) + public function handle(Client $guzzle): void { //send webmention $response = $guzzle->request( @@ -52,7 +48,7 @@ class SyndicateBookmarkToTwitter implements ShouldQueue ] ); //parse for syndication URL - if ($response->getStatusCode() == 201) { + if ($response->getStatusCode() === 201) { $json = json_decode((string) $response->getBody()); $syndicates = $this->bookmark->syndicates; $syndicates['twitter'] = $json->url; diff --git a/app/Jobs/SyndicateNoteToMastodon.php b/app/Jobs/SyndicateNoteToMastodon.php index d3346470..557006a4 100644 --- a/app/Jobs/SyndicateNoteToMastodon.php +++ b/app/Jobs/SyndicateNoteToMastodon.php @@ -19,8 +19,6 @@ class SyndicateNoteToMastodon implements ShouldQueue /** * Create a new job instance. - * - * @return void */ public function __construct( protected Note $note @@ -30,7 +28,6 @@ class SyndicateNoteToMastodon implements ShouldQueue /** * Execute the job. * - * * @throws GuzzleException */ public function handle(Client $guzzle): void diff --git a/app/Jobs/SyndicateNoteToTwitter.php b/app/Jobs/SyndicateNoteToTwitter.php index 2d6c7838..4edf10c2 100644 --- a/app/Jobs/SyndicateNoteToTwitter.php +++ b/app/Jobs/SyndicateNoteToTwitter.php @@ -18,15 +18,12 @@ class SyndicateNoteToTwitter implements ShouldQueue use Queueable; use SerializesModels; - /** @var Note */ - protected $note; - /** * Create a new job instance. */ - public function __construct(Note $note) - { - $this->note = $note; + public function __construct( + protected Note $note + ) { } /** diff --git a/app/Models/Article.php b/app/Models/Article.php index 0e33ed0f..5b660076 100644 --- a/app/Models/Article.php +++ b/app/Models/Article.php @@ -24,20 +24,24 @@ class Article extends Model use Sluggable; use SoftDeletes; - /** - * The attributes that should be mutated to dates. - * - * @var array - */ - protected $dates = ['created_at', 'updated_at', 'deleted_at']; - - /** - * The database table used by the model. - * - * @var string - */ + /** @var string */ protected $table = 'articles'; + /** @var array */ + protected $fillable = [ + 'url', + 'title', + 'main', + 'published', + ]; + + /** @var array */ + protected $casts = [ + 'created_at' => 'datetime', + 'updated_at' => 'datetime', + 'deleted_at' => 'datetime', + ]; + /** * Return the sluggable configuration array for this model. */ @@ -50,18 +54,6 @@ class Article extends Model ]; } - /** - * The attributes that are mass assignable. - * - * @var array - */ - protected $fillable = [ - 'url', - 'title', - 'main', - 'published', - ]; - protected function html(): Attribute { return Attribute::get( diff --git a/app/Models/Bookmark.php b/app/Models/Bookmark.php index 097b461e..29bd25ad 100644 --- a/app/Models/Bookmark.php +++ b/app/Models/Bookmark.php @@ -13,28 +13,15 @@ class Bookmark extends Model { use HasFactory; - /** - * The attributes that are mass assignable. - * - * @var array - */ + /** @var array */ protected $fillable = ['url', 'name', 'content']; - /** - * The attributes that should be cast to native types. - * - * @var array - */ + /** @var array */ protected $casts = [ 'syndicates' => 'array', ]; - /** - * The tags that belong to the bookmark. - * - * @return BelongsToMany - */ - public function tags() + public function tags(): BelongsToMany { return $this->belongsToMany('App\Models\Tag'); } diff --git a/app/Models/Contact.php b/app/Models/Contact.php index 1da4d7ba..6f193f41 100644 --- a/app/Models/Contact.php +++ b/app/Models/Contact.php @@ -12,18 +12,10 @@ class Contact extends Model { use HasFactory; - /** - * The database table used by the model. - * - * @var string - */ + /** @var string */ protected $table = 'contacts'; - /** - * We shall guard against mass-migration. - * - * @var array - */ + /** @var array */ protected $fillable = ['nick', 'name', 'homepage', 'twitter', 'facebook']; protected function photo(): Attribute diff --git a/app/Models/Like.php b/app/Models/Like.php index 074fb9bd..f9ac3bcb 100644 --- a/app/Models/Like.php +++ b/app/Models/Like.php @@ -16,6 +16,7 @@ class Like extends Model use FilterHtml; use HasFactory; + /** @var array */ protected $fillable = ['url']; protected function url(): Attribute diff --git a/app/Models/Media.php b/app/Models/Media.php index de88e9b8..c4dd6d5c 100644 --- a/app/Models/Media.php +++ b/app/Models/Media.php @@ -14,23 +14,12 @@ class Media extends Model { use HasFactory; - /** - * The table associated with the model. - * - * @var string - */ + /** @var string */ protected $table = 'media_endpoint'; - /** - * The attributes that are mass assignable. - * - * @var array - */ + /** @var array */ protected $fillable = ['token', 'path', 'type', 'image_widths']; - /** - * Get the note that owns this media. - */ public function note(): BelongsTo { return $this->belongsTo(Note::class); diff --git a/app/Models/MicropubClient.php b/app/Models/MicropubClient.php index bb8bdfcf..669c7284 100644 --- a/app/Models/MicropubClient.php +++ b/app/Models/MicropubClient.php @@ -12,23 +12,12 @@ class MicropubClient extends Model { use HasFactory; - /** - * The table associated with the model. - * - * @var string - */ + /** @var string */ protected $table = 'clients'; - /** - * The attributes that are mass assignable. - * - * @var array - */ + /** @var array */ protected $fillable = ['client_url', 'client_name']; - /** - * Define the relationship with notes. - */ public function notes(): HasMany { return $this->hasMany('App\Models\Note', 'client_id', 'client_url'); diff --git a/app/Models/Note.php b/app/Models/Note.php index 9326207e..e385d908 100644 --- a/app/Models/Note.php +++ b/app/Models/Note.php @@ -6,7 +6,6 @@ namespace App\Models; use App\CommonMark\Generators\ContactMentionGenerator; use App\CommonMark\Renderers\ContactMentionRenderer; -use App\Exceptions\TwitterContentException; use Codebird\Codebird; use Exception; use GuzzleHttp\Client; @@ -58,73 +57,46 @@ class Note extends Model $this->contacts = null; } - /** - * The database table used by the model. - * - * @var string - */ + /** @var string */ protected $table = 'notes'; - /** - * Mass-assignment. - * - * @var array - */ + /** @var array */ protected $fillable = [ 'note', 'in_reply_to', 'client_id', ]; - /** - * Hide the column used with Laravel Scout. - * - * @var array - */ + /** @var array */ protected $hidden = ['searchable']; - /** - * Define the relationship with tags. - */ public function tags(): BelongsToMany { return $this->belongsToMany(Tag::class); } - /** - * Define the relationship with clients. - */ public function client(): BelongsTo { return $this->belongsTo(MicropubClient::class, 'client_id', 'client_url'); } - /** - * Define the relationship with webmentions. - */ public function webmentions(): MorphMany { return $this->morphMany(WebMention::class, 'commentable'); } - /** - * Define the relationship with places. - */ public function place(): BelongsTo { return $this->belongsTo(Place::class); } - /** - * Define the relationship with media. - */ public function media(): HasMany { return $this->hasMany(Media::class); } /** - * Set the attributes to be indexed for searching with Scout. + * @return array */ public function toSearchableArray(): array { @@ -133,9 +105,6 @@ class Note extends Model ]; } - /** - * Normalize the note to Unicode FORM C. - */ public function setNoteAttribute(?string $value): void { if ($value !== null) { @@ -195,58 +164,37 @@ class Note extends Model return $note; } - /** - * Generate the NewBase60 ID from primary ID. - */ public function getNb60idAttribute(): string { // we cast to string because sometimes the nb60id is an “int” return (string) resolve(Numbers::class)->numto60($this->id); } - /** - * The Long URL for a note. - */ public function getLongurlAttribute(): string { return config('app.url') . '/notes/' . $this->nb60id; } - /** - * The Short URL for a note. - */ public function getShorturlAttribute(): string { return config('app.shorturl') . '/notes/' . $this->nb60id; } - /** - * Get the ISO8601 value for mf2. - */ public function getIso8601Attribute(): string { return $this->updated_at->toISO8601String(); } - /** - * Get the ISO8601 value for mf2. - */ public function getHumandiffAttribute(): string { return $this->updated_at->diffForHumans(); } - /** - * Get the publish date value for RSS feeds. - */ public function getPubdateAttribute(): string { return $this->updated_at->toRSSString(); } - /** - * Get the latitude value. - */ public function getLatitudeAttribute(): ?float { if ($this->place !== null) { @@ -262,9 +210,6 @@ class Note extends Model return null; } - /** - * Get the longitude value. - */ public function getLongitudeAttribute(): ?float { if ($this->place !== null) { @@ -281,8 +226,9 @@ class Note extends Model } /** - * Get the address for a note. This is either a reverse geo-code from the - * location, or is derived from the associated place. + * Get the address for a note. + * + * This is either a reverse geo-code from the location, or is derived from the associated place. */ public function getAddressAttribute(): ?string { @@ -337,9 +283,6 @@ class Note extends Model * Show a specific form of the note for twitter. * * That is we swap the contacts names for their known Twitter handles. - * - * - * @throws TwitterContentException */ public function getTwitterContentAttribute(): string { @@ -389,7 +332,7 @@ class Note extends Model } /** - * Swap contact’s nicks for a full mf2 h-card. + * Swap contact’s nicks for a full mf2 h-card. * * Take note that this method does two things, given @username (NOT [@username](URL)!) * we try to create a fancy hcard from our contact info. If this is not possible @@ -473,9 +416,6 @@ class Note extends Model ); } - /** - * Pass a note through the commonmark library. - */ private function convertMarkdown(string $note): string { $config = [ @@ -500,9 +440,6 @@ class Note extends Model return $markdownConverter->convert($note)->getContent(); } - /** - * Do a reverse geocode lookup of a `lat,lng` value. - */ public function reverseGeoCode(float $latitude, float $longitude): string { $latLng = $latitude . ',' . $longitude; diff --git a/app/Models/Place.php b/app/Models/Place.php index b49cf87d..dd8320d6 100644 --- a/app/Models/Place.php +++ b/app/Models/Place.php @@ -17,36 +17,20 @@ class Place extends Model use HasFactory; use Sluggable; - /** - * Get the route key for the model. - * - * @return string - */ - public function getRouteKeyName() + public function getRouteKeyName(): string { return 'slug'; } - /** - * The attributes that are mass assignable. - * - * @var array - */ + /** @var array */ protected $fillable = ['name', 'slug']; - /** - * The attributes that should be cast. - * - * @var array - */ + /** @var array */ protected $casts = [ 'latitude' => 'float', 'longitude' => 'float', ]; - /** - * Return the sluggable configuration array for this model. - */ public function sluggable(): array { return [ @@ -57,12 +41,7 @@ class Place extends Model ]; } - /** - * Define the relationship with Notes. - * - * @return HasMany - */ - public function notes() + public function notes(): HasMany { return $this->hasMany('App\Models\Note'); } diff --git a/app/Models/SyndicationTarget.php b/app/Models/SyndicationTarget.php index 85d674c1..ec2d046a 100644 --- a/app/Models/SyndicationTarget.php +++ b/app/Models/SyndicationTarget.php @@ -12,11 +12,7 @@ class SyndicationTarget extends Model { use HasFactory; - /** - * The attributes that are mass assignable. - * - * @var array - */ + /** @var array */ protected $fillable = [ 'uid', 'name', @@ -28,11 +24,7 @@ class SyndicationTarget extends Model 'user_photo', ]; - /** - * The attributes that are visible when serializing the model. - * - * @var array - */ + /** @var array */ protected $visible = [ 'uid', 'name', @@ -40,21 +32,12 @@ class SyndicationTarget extends Model 'user', ]; - /** - * The accessors to append to the model's array form. - * - * @var array - */ + /** @var array */ protected $appends = [ 'service', 'user', ]; - /** - * Get the service data as a single attribute. - * - * @vreturn Attribute - */ protected function service(): Attribute { return Attribute::get( @@ -66,11 +49,6 @@ class SyndicationTarget extends Model ); } - /** - * Get the user data as a single attribute. - * - * @vreturn Attribute - */ protected function user(): Attribute { return Attribute::get( diff --git a/app/Models/Tag.php b/app/Models/Tag.php index c573c7c6..41c75c75 100644 --- a/app/Models/Tag.php +++ b/app/Models/Tag.php @@ -14,29 +14,15 @@ class Tag extends Model { use HasFactory; - /** - * We shall set a blacklist of non-modifiable model attributes. - * - * @var array - */ + /** @var array */ protected $guarded = ['id']; - /** - * Define the relationship with notes. - * - * @return BelongsToMany - */ - public function notes() + public function notes(): BelongsToMany { return $this->belongsToMany(Note::class); } - /** - * The bookmarks that belong to the tag. - * - * @return BelongsToMany - */ - public function bookmarks() + public function bookmarks(): BelongsToMany { return $this->belongsToMany('App\Models\Bookmark'); } @@ -49,8 +35,9 @@ class Tag extends Model } /** - * This method actually normalizes a tag. That means lowercase-ing and - * removing fancy diatric characters. + * Normalizes a tag. + * + * That means convert to lowercase and removing fancy diatric characters. */ public static function normalize(string $tag): string { diff --git a/app/Models/User.php b/app/Models/User.php index c4d76e1e..bc57ee54 100644 --- a/app/Models/User.php +++ b/app/Models/User.php @@ -13,21 +13,15 @@ class User extends Authenticatable use HasFactory; use Notifiable; - /** - * The attributes that are mass assignable. - * - * @var array - */ + /** @var array */ protected $fillable = [ 'name', 'password', ]; - /** - * The attributes that should be hidden for arrays. - * - * @var array - */ + /** @var array */ protected $hidden = [ - 'password', 'remember_token', + 'current_password', + 'password', + 'remember_token', ]; } diff --git a/app/Models/WebMention.php b/app/Models/WebMention.php index 3464e93a..a1514517 100644 --- a/app/Models/WebMention.php +++ b/app/Models/WebMention.php @@ -20,26 +20,13 @@ class WebMention extends Model use FilterHtml; use HasFactory; - /** - * The database table used by the model. - * - * @var string - */ + /** @var string */ protected $table = 'webmentions'; - /** - * We shall set a blacklist of non-modifiable model attributes. - * - * @var array - */ + /** @var array */ protected $guarded = ['id']; - /** - * Define the relationship. - * - * @return MorphTo - */ - public function commentable() + public function commentable(): MorphTo { return $this->morphTo(); } diff --git a/app/Observers/NoteObserver.php b/app/Observers/NoteObserver.php index 07033cd0..d4b3120c 100644 --- a/app/Observers/NoteObserver.php +++ b/app/Observers/NoteObserver.php @@ -14,7 +14,7 @@ class NoteObserver /** * Listen to the Note created event. */ - public function created(Note $note) + public function created(Note $note): void { $text = Arr::get($note->getAttributes(), 'note'); if ($text === null) { @@ -36,7 +36,7 @@ class NoteObserver /** * Listen to the Note updated event. */ - public function updated(Note $note) + public function updated(Note $note): void { $text = Arr::get($note->getAttributes(), 'note'); if ($text === null) { @@ -60,7 +60,7 @@ class NoteObserver /** * Listen to the Note deleting event. */ - public function deleting(Note $note) + public function deleting(Note $note): void { $note->tags()->detach(); } diff --git a/app/Providers/AppServiceProvider.php b/app/Providers/AppServiceProvider.php index 03bfa4aa..67d7a2f4 100644 --- a/app/Providers/AppServiceProvider.php +++ b/app/Providers/AppServiceProvider.php @@ -25,10 +25,8 @@ class AppServiceProvider extends ServiceProvider { /** * Bootstrap any application services. - * - * @return void */ - public function boot() + public function boot(): void { Note::observe(NoteObserver::class); @@ -144,10 +142,8 @@ class AppServiceProvider extends ServiceProvider /** * Register any application services. - * - * @return void */ - public function register() + public function register(): void { if ($this->app->environment('local', 'testing')) { $this->app->register(DuskServiceProvider::class); diff --git a/app/Providers/AuthServiceProvider.php b/app/Providers/AuthServiceProvider.php index 71d8474d..faa84c0d 100644 --- a/app/Providers/AuthServiceProvider.php +++ b/app/Providers/AuthServiceProvider.php @@ -7,23 +7,19 @@ use Illuminate\Foundation\Support\Providers\AuthServiceProvider as ServiceProvid class AuthServiceProvider extends ServiceProvider { /** - * The policy mappings for the application. + * The model to policy mappings for the application. * - * @var array + * @var array */ protected $policies = [ // 'App\Models\Model' => 'App\Policies\ModelPolicy', ]; /** - * Register any application authentication / authorization services. - * - * @return void + * Register any authentication / authorization services. */ - public function boot() + public function boot(): void { - $this->registerPolicies(); - // } } diff --git a/app/Providers/BroadcastServiceProvider.php b/app/Providers/BroadcastServiceProvider.php index c1f5ec4b..147f27b7 100644 --- a/app/Providers/BroadcastServiceProvider.php +++ b/app/Providers/BroadcastServiceProvider.php @@ -12,10 +12,8 @@ class BroadcastServiceProvider extends ServiceProvider { /** * Bootstrap any application services. - * - * @return void */ - public function boot() + public function boot(): void { Broadcast::routes(); diff --git a/app/Providers/EventServiceProvider.php b/app/Providers/EventServiceProvider.php index 723a290d..3b514f53 100644 --- a/app/Providers/EventServiceProvider.php +++ b/app/Providers/EventServiceProvider.php @@ -10,9 +10,9 @@ use Illuminate\Support\Facades\Event; class EventServiceProvider extends ServiceProvider { /** - * The event listener mappings for the application. + * The event to listener mappings for the application. * - * @var array + * @var array> */ protected $listen = [ Registered::class => [ @@ -22,13 +22,9 @@ class EventServiceProvider extends ServiceProvider /** * Register any events for your application. - * - * @return void */ - public function boot() + public function boot(): void { - parent::boot(); - // } } diff --git a/app/Providers/HorizonServiceProvider.php b/app/Providers/HorizonServiceProvider.php index 89a3c7b4..4d54239b 100644 --- a/app/Providers/HorizonServiceProvider.php +++ b/app/Providers/HorizonServiceProvider.php @@ -10,10 +10,8 @@ class HorizonServiceProvider extends HorizonApplicationServiceProvider { /** * Bootstrap any application services. - * - * @return void */ - public function boot() + public function boot(): void { parent::boot(); @@ -28,10 +26,8 @@ class HorizonServiceProvider extends HorizonApplicationServiceProvider * Register the Horizon gate. * * This gate determines who can access Horizon in non-local environments. - * - * @return void */ - protected function gate() + protected function gate(): void { Gate::define('viewHorizon', function ($user) { return $user->name === 'jonny'; diff --git a/app/Providers/RouteServiceProvider.php b/app/Providers/RouteServiceProvider.php index 3f8af660..caecf5f4 100644 --- a/app/Providers/RouteServiceProvider.php +++ b/app/Providers/RouteServiceProvider.php @@ -11,46 +11,38 @@ use Illuminate\Support\Facades\Route; class RouteServiceProvider extends ServiceProvider { /** - * This namespace is applied to your controller routes. + * The path to the "home" route for your application. * - * In addition, it is set as the URL generator's root namespace. + * Typically, users are redirected here after authentication. * - * @var string|null + * @var string */ - // protected $namespace = 'App\Http\Controllers'; + public const HOME = '/admin'; /** - * Define your route model bindings, pattern filters, etc. - * - * @return void + * Define your route model bindings, pattern filters, and other route configuration. */ - public function boot() + public function boot(): void { $this->configureRateLimiting(); $this->routes(function () { - Route::prefix('api') - ->middleware('api') - ->namespace($this->namespace) + Route::middleware('api') + ->prefix('api') ->group(base_path('routes/api.php')); Route::middleware('web') - ->namespace($this->namespace) ->group(base_path('routes/web.php')); }); } /** * Configure the rate limiters for the application. - * - * @return void - * - * @codeCoverageIgnore */ - protected function configureRateLimiting() + protected function configureRateLimiting(): void { RateLimiter::for('api', function (Request $request) { - return Limit::perMinute(60); + return Limit::perMinute(60)->by($request->user()?->id ?: $request->ip()); }); } } diff --git a/app/Services/ActivityStreamsService.php b/app/Services/ActivityStreamsService.php index db7a1917..e439e539 100644 --- a/app/Services/ActivityStreamsService.php +++ b/app/Services/ActivityStreamsService.php @@ -5,15 +5,14 @@ declare(strict_types=1); namespace App\Services; use App\Models\Note; +use Illuminate\Http\Response; class ActivityStreamsService { /** * Return the relevant data to an AS2.0 request to the root path. - * - * @return \Illuminate\Http\Response */ - public function siteOwnerResponse() + public function siteOwnerResponse(): Response { $data = json_encode([ '@context' => 'https://www.w3.org/ns/activitystreams', @@ -28,10 +27,8 @@ class ActivityStreamsService /** * Return the relevant data to an AS2.0 request for a particular note. - * - * @return \Illuminate\Http\Response */ - public function singleNoteResponse(Note $note) + public function singleNoteResponse(Note $note): Response { $data = json_encode([ '@context' => 'https://www.w3.org/ns/activitystreams', diff --git a/app/Services/BookmarkService.php b/app/Services/BookmarkService.php index 9078153e..afed64fc 100644 --- a/app/Services/BookmarkService.php +++ b/app/Services/BookmarkService.php @@ -19,8 +19,6 @@ class BookmarkService extends Service { /** * Create a new Bookmark. - * - * @param array $request Data from request()->all() */ public function create(array $request, ?string $client = null): Bookmark { @@ -74,7 +72,6 @@ class BookmarkService extends Service /** * Given a URL, attempt to save it to the Internet Archive. * - * * @throws InternetArchiveException */ public function getArchiveLink(string $url): string diff --git a/app/Services/LikeService.php b/app/Services/LikeService.php index b1168c27..efd2216b 100644 --- a/app/Services/LikeService.php +++ b/app/Services/LikeService.php @@ -12,8 +12,6 @@ class LikeService extends Service { /** * Create a new Like. - * - * @return Like $like */ public function create(array $request, ?string $client = null): Like { diff --git a/app/Services/Micropub/HCardService.php b/app/Services/Micropub/HCardService.php index 1685351c..7ab57a4e 100644 --- a/app/Services/Micropub/HCardService.php +++ b/app/Services/Micropub/HCardService.php @@ -11,8 +11,6 @@ class HCardService { /** * Create a Place from h-card data, return the URL. - * - * @param array $request Data from request()->all() */ public function process(array $request): string { @@ -28,8 +26,7 @@ class HCardService $data['latitude'] = Arr::get($request, 'latitude'); $data['longitude'] = Arr::get($request, 'longitude'); } - $place = resolve(PlaceService::class)->createPlace($data); - return $place->longurl; + return resolve(PlaceService::class)->createPlace($data)->longurl; } } diff --git a/app/Services/Micropub/HEntryService.php b/app/Services/Micropub/HEntryService.php index 9011540c..807e6327 100644 --- a/app/Services/Micropub/HEntryService.php +++ b/app/Services/Micropub/HEntryService.php @@ -13,10 +13,7 @@ use Illuminate\Support\Arr; class HEntryService { /** - * Create the relavent model from some h-entry data. - * - * @param array $request Data from request()->all() - * @param string|null $client The micropub client that made the request + * Create the relevant model from some h-entry data. */ public function process(array $request, ?string $client = null): ?string { diff --git a/app/Services/Micropub/UpdateService.php b/app/Services/Micropub/UpdateService.php index f056c475..ac9d360a 100644 --- a/app/Services/Micropub/UpdateService.php +++ b/app/Services/Micropub/UpdateService.php @@ -7,6 +7,7 @@ namespace App\Services\Micropub; use App\Models\Media; use App\Models\Note; use Illuminate\Database\Eloquent\ModelNotFoundException; +use Illuminate\Http\JsonResponse; use Illuminate\Support\Arr; use Illuminate\Support\Str; @@ -14,11 +15,8 @@ class UpdateService { /** * Process a micropub request to update an entry. - * - * @param array $request Data from request()->all() - * @return \Illuminate\Http\JsonResponse */ - public function process(array $request) + public function process(array $request): JsonResponse { $urlPath = parse_url(Arr::get($request, 'url'), PHP_URL_PATH); @@ -42,10 +40,10 @@ class UpdateService //got the note, are we dealing with a “replace” request? if (Arr::get($request, 'replace')) { foreach (Arr::get($request, 'replace') as $property => $value) { - if ($property == 'content') { + if ($property === 'content') { $note->note = $value[0]; } - if ($property == 'syndication') { + if ($property === 'syndication') { foreach ($value as $syndicationURL) { if (Str::startsWith($syndicationURL, 'https://www.facebook.com')) { $note->facebook_url = $syndicationURL; @@ -69,7 +67,7 @@ class UpdateService //how about “add” if (Arr::get($request, 'add')) { foreach (Arr::get($request, 'add') as $property => $value) { - if ($property == 'syndication') { + if ($property === 'syndication') { foreach ($value as $syndicationURL) { if (Str::startsWith($syndicationURL, 'https://www.facebook.com')) { $note->facebook_url = $syndicationURL; @@ -82,7 +80,7 @@ class UpdateService } } } - if ($property == 'photo') { + if ($property === 'photo') { foreach ($value as $photoURL) { if (Str::startsWith($photoURL, 'https://')) { $media = new Media(); diff --git a/app/Services/NoteService.php b/app/Services/NoteService.php index 4119c38b..28ee5104 100644 --- a/app/Services/NoteService.php +++ b/app/Services/NoteService.php @@ -18,8 +18,6 @@ class NoteService extends Service { /** * Create a new note. - * - * @param array $request Data from request()->all() */ public function create(array $request, ?string $client = null): Note { @@ -66,8 +64,6 @@ class NoteService extends Service /** * Get the published time from the request to create a new note. - * - * @param array $request Data from request()->all() */ private function getPublished(array $request): ?string { @@ -84,13 +80,11 @@ class NoteService extends Service /** * Get the location data from the request to create a new note. - * - * @param array $request Data from request()->all() */ private function getLocation(array $request): ?string { $location = Arr::get($request, 'properties.location.0') ?? Arr::get($request, 'location'); - if (is_string($location) && substr($location, 0, 4) == 'geo:') { + if (is_string($location) && str_starts_with($location, 'geo:')) { preg_match_all( '/([0-9\.\-]+)/', $location, @@ -105,8 +99,6 @@ class NoteService extends Service /** * Get the checkin data from the request to create a new note. This will be a Place. - * - * @param array $request Data from request()->all() */ private function getCheckin(array $request): ?Place { @@ -150,12 +142,10 @@ class NoteService extends Service /** * Get the Swarm URL from the syndication data in the request to create a new note. - * - * @param array $request Data from request()->all() */ private function getSwarmUrl(array $request): ?string { - if (stristr(Arr::get($request, 'properties.syndication.0', ''), 'swarmapp')) { + if (str_contains(Arr::get($request, 'properties.syndication.0', ''), 'swarmapp')) { return Arr::get($request, 'properties.syndication.0'); } @@ -164,8 +154,6 @@ class NoteService extends Service /** * Get the syndication targets from the request to create a new note. - * - * @param array $request Data from request()->all() */ private function getSyndicationTargets(array $request): array { @@ -187,8 +175,6 @@ class NoteService extends Service /** * Get the media URLs from the request to create a new note. - * - * @param array $request Data from request()->all() */ private function getMedia(array $request): array { @@ -216,8 +202,6 @@ class NoteService extends Service /** * Get the Instagram photo URL from the request to create a new note. - * - * @param array $request Data from request()->all() */ private function getInstagramUrl(array $request): ?string { diff --git a/app/Services/PlaceService.php b/app/Services/PlaceService.php index 3b2de225..d3756253 100644 --- a/app/Services/PlaceService.php +++ b/app/Services/PlaceService.php @@ -37,8 +37,6 @@ class PlaceService /** * Create a place from a h-card checkin, for example from OwnYourSwarm. - * - * @param array */ public function createPlaceFromCheckin(array $checkin): Place { diff --git a/app/Services/TokenService.php b/app/Services/TokenService.php index 844852fb..fddccff0 100644 --- a/app/Services/TokenService.php +++ b/app/Services/TokenService.php @@ -13,9 +13,6 @@ class TokenService { /** * Generate a JWT token. - * - * @param array The data to be encoded - * @return string The signed token */ public function getNewToken(array $data): string { @@ -36,9 +33,6 @@ class TokenService /** * Check the token signature is valid. - * - * @param string The token - * @return mixed */ public function validateToken(string $bearerToken): Token { diff --git a/artisan b/artisan index 5c23e2e2..67a3329b 100755 --- a/artisan +++ b/artisan @@ -11,7 +11,7 @@ define('LARAVEL_START', microtime(true)); | Composer provides a convenient, automatically generated class loader | for our application. We just need to utilize it! We'll require it | into the script here so that we do not have to worry about the -| loading of any our classes "manually". Feels great to relax. +| loading of any of our classes manually. It's great to relax. | */ diff --git a/composer.json b/composer.json index 33cf43fc..adc76904 100644 --- a/composer.json +++ b/composer.json @@ -13,14 +13,14 @@ "ext-dom": "*", "ext-intl": "*", "ext-json": "*", - "cviebrock/eloquent-sluggable": "^9.0", + "cviebrock/eloquent-sluggable": "^10.0", "guzzlehttp/guzzle": "^7.0.1", "indieauth/client": "^1.1", "intervention/image": "^2.4", "jonnybarnes/indieweb": "~0.2", "jonnybarnes/webmentions-parser": "~0.5", "jublonet/codebird-php": "4.0.0-beta.1", - "laravel/framework": "^9.0", + "laravel/framework": "^10.0", "laravel/horizon": "^5.0", "laravel/sanctum": "^3.0", "laravel/tinker": "^2.0", @@ -40,10 +40,10 @@ "laravel/pint": "^1.0.0", "laravel/sail": "^1.15", "mockery/mockery": "^1.0", - "nunomaduro/collision": "^6.0", - "phpunit/php-code-coverage": "^9.2", - "phpunit/phpunit": "^9.0", - "spatie/laravel-ignition": "^1.0", + "nunomaduro/collision": "^7.0", + "phpunit/php-code-coverage": "^10.0", + "phpunit/phpunit": "^10.0", + "spatie/laravel-ignition": "^2.0", "spatie/laravel-ray": "^1.12", "vimeo/psalm": "^5.0" }, @@ -76,7 +76,7 @@ "Tests\\": "tests" } }, - "minimum-stability": "dev", + "minimum-stability": "stable", "prefer-stable": true, "scripts": { "post-autoload-dump": [ diff --git a/composer.lock b/composer.lock index 066dd246..88ba8dba 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "81714df7ed555e945818b8c87469873a", + "content-hash": "eb2414fc51239282393ccf0cda599ca9", "packages": [ { "name": "aws/aws-crt-php", @@ -58,16 +58,16 @@ }, { "name": "aws/aws-sdk-php", - "version": "3.258.3", + "version": "3.258.12", "source": { "type": "git", "url": "https://github.com/aws/aws-sdk-php.git", - "reference": "57cbc06827148d0d4d3f5dbe4b948daa20f82d70" + "reference": "43ee875456822ee7772cfc51da57bfa558ccb30c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/aws/aws-sdk-php/zipball/57cbc06827148d0d4d3f5dbe4b948daa20f82d70", - "reference": "57cbc06827148d0d4d3f5dbe4b948daa20f82d70", + "url": "https://api.github.com/repos/aws/aws-sdk-php/zipball/43ee875456822ee7772cfc51da57bfa558ccb30c", + "reference": "43ee875456822ee7772cfc51da57bfa558ccb30c", "shasum": "" }, "require": { @@ -146,31 +146,32 @@ "support": { "forum": "https://forums.aws.amazon.com/forum.jspa?forumID=80", "issues": "https://github.com/aws/aws-sdk-php/issues", - "source": "https://github.com/aws/aws-sdk-php/tree/3.258.3" + "source": "https://github.com/aws/aws-sdk-php/tree/3.258.12" }, - "time": "2023-02-03T19:25:20+00:00" + "time": "2023-02-16T19:21:12+00:00" }, { "name": "brick/math", - "version": "0.11.0", + "version": "0.10.2", "source": { "type": "git", "url": "https://github.com/brick/math.git", - "reference": "0ad82ce168c82ba30d1c01ec86116ab52f589478" + "reference": "459f2781e1a08d52ee56b0b1444086e038561e3f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/brick/math/zipball/0ad82ce168c82ba30d1c01ec86116ab52f589478", - "reference": "0ad82ce168c82ba30d1c01ec86116ab52f589478", + "url": "https://api.github.com/repos/brick/math/zipball/459f2781e1a08d52ee56b0b1444086e038561e3f", + "reference": "459f2781e1a08d52ee56b0b1444086e038561e3f", "shasum": "" }, "require": { - "php": "^8.0" + "ext-json": "*", + "php": "^7.4 || ^8.0" }, "require-dev": { "php-coveralls/php-coveralls": "^2.2", "phpunit/phpunit": "^9.0", - "vimeo/psalm": "5.0.0" + "vimeo/psalm": "4.25.0" }, "type": "library", "autoload": { @@ -195,7 +196,7 @@ ], "support": { "issues": "https://github.com/brick/math/issues", - "source": "https://github.com/brick/math/tree/0.11.0" + "source": "https://github.com/brick/math/tree/0.10.2" }, "funding": [ { @@ -203,7 +204,7 @@ "type": "github" } ], - "time": "2023-01-15T23:15:59+00:00" + "time": "2022-08-10T22:54:19+00:00" }, { "name": "cocur/slugify", @@ -432,31 +433,30 @@ }, { "name": "cviebrock/eloquent-sluggable", - "version": "9.0.0", + "version": "10.0.0", "source": { "type": "git", "url": "https://github.com/cviebrock/eloquent-sluggable.git", - "reference": "3100e37682491424dd13eaeb3ec33cbbad186992" + "reference": "92f456b10337ca97c1cccfcc853a1cf51d2cedd0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/cviebrock/eloquent-sluggable/zipball/3100e37682491424dd13eaeb3ec33cbbad186992", - "reference": "3100e37682491424dd13eaeb3ec33cbbad186992", + "url": "https://api.github.com/repos/cviebrock/eloquent-sluggable/zipball/92f456b10337ca97c1cccfcc853a1cf51d2cedd0", + "reference": "92f456b10337ca97c1cccfcc853a1cf51d2cedd0", "shasum": "" }, "require": { - "cocur/slugify": "^4.0", - "illuminate/config": "^9.0", - "illuminate/database": "^9.0", - "illuminate/support": "^9.0", - "php": "^8.0" + "cocur/slugify": "^4.3", + "illuminate/config": "^10.0", + "illuminate/database": "^10.0", + "illuminate/support": "^10.0", + "php": "^8.1" }, "require-dev": { "limedeck/phpunit-detailed-printer": "^6.0", - "mockery/mockery": "^1.4.2", - "orchestra/database": "^7.0", - "orchestra/testbench": "^7.0", - "phpunit/phpunit": "^9.4" + "mockery/mockery": "^1.4.4", + "orchestra/testbench": "^8.0", + "pestphp/pest": "2.x-dev" }, "type": "library", "extra": { @@ -493,7 +493,7 @@ ], "support": { "issues": "https://github.com/cviebrock/eloquent-sluggable/issues", - "source": "https://github.com/cviebrock/eloquent-sluggable/tree/9.0.0" + "source": "https://github.com/cviebrock/eloquent-sluggable/tree/10.0.0" }, "funding": [ { @@ -501,7 +501,7 @@ "type": "github" } ], - "time": "2022-01-25T02:55:58+00:00" + "time": "2023-02-16T23:01:35+00:00" }, { "name": "dflydev/dot-access-data", @@ -1824,20 +1824,21 @@ }, { "name": "laravel/framework", - "version": "v9.52.0", + "version": "v10.0.3", "source": { "type": "git", "url": "https://github.com/laravel/framework.git", - "reference": "eb85cd9d72e5bfa54b4d0d9040786f26d6184a9e" + "reference": "0bd303853444de33f4fcb16d13bd7574030aa3d4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laravel/framework/zipball/eb85cd9d72e5bfa54b4d0d9040786f26d6184a9e", - "reference": "eb85cd9d72e5bfa54b4d0d9040786f26d6184a9e", + "url": "https://api.github.com/repos/laravel/framework/zipball/0bd303853444de33f4fcb16d13bd7574030aa3d4", + "reference": "0bd303853444de33f4fcb16d13bd7574030aa3d4", "shasum": "" }, "require": { "brick/math": "^0.9.3|^0.10.2|^0.11", + "composer-runtime-api": "^2.2", "doctrine/inflector": "^2.0.5", "dragonmantank/cron-expression": "^3.3.2", "egulias/email-validator": "^3.2.1|^4.0", @@ -1850,28 +1851,28 @@ "ext-tokenizer": "*", "fruitcake/php-cors": "^1.2", "guzzlehttp/uri-template": "^1.0", - "laravel/serializable-closure": "^1.2.2", + "laravel/serializable-closure": "^1.3", "league/commonmark": "^2.2.1", "league/flysystem": "^3.8.0", - "monolog/monolog": "^2.0", + "monolog/monolog": "^3.0", "nesbot/carbon": "^2.62.1", "nunomaduro/termwind": "^1.13", - "php": "^8.0.2", + "php": "^8.1", "psr/container": "^1.1.1|^2.0.1", "psr/log": "^1.0|^2.0|^3.0", "psr/simple-cache": "^1.0|^2.0|^3.0", "ramsey/uuid": "^4.7", - "symfony/console": "^6.0.9", - "symfony/error-handler": "^6.0", - "symfony/finder": "^6.0", - "symfony/http-foundation": "^6.0", - "symfony/http-kernel": "^6.0", - "symfony/mailer": "^6.0", - "symfony/mime": "^6.0", - "symfony/process": "^6.0", - "symfony/routing": "^6.0", - "symfony/uid": "^6.0", - "symfony/var-dumper": "^6.0", + "symfony/console": "^6.2", + "symfony/error-handler": "^6.2", + "symfony/finder": "^6.2", + "symfony/http-foundation": "^6.2", + "symfony/http-kernel": "^6.2", + "symfony/mailer": "^6.2", + "symfony/mime": "^6.2", + "symfony/process": "^6.2", + "symfony/routing": "^6.2", + "symfony/uid": "^6.2", + "symfony/var-dumper": "^6.2", "tijsverkoyen/css-to-inline-styles": "^2.2.5", "vlucas/phpdotenv": "^5.4.1", "voku/portable-ascii": "^2.0" @@ -1907,6 +1908,7 @@ "illuminate/notifications": "self.version", "illuminate/pagination": "self.version", "illuminate/pipeline": "self.version", + "illuminate/process": "self.version", "illuminate/queue": "self.version", "illuminate/redis": "self.version", "illuminate/routing": "self.version", @@ -1920,7 +1922,7 @@ "require-dev": { "ably/ably-php": "^1.0", "aws/aws-sdk-php": "^3.235.5", - "doctrine/dbal": "^2.13.3|^3.1.4", + "doctrine/dbal": "^3.5.1", "ext-gmp": "*", "fakerphp/faker": "^1.21", "guzzlehttp/guzzle": "^7.5", @@ -1930,20 +1932,20 @@ "league/flysystem-read-only": "^3.3", "league/flysystem-sftp-v3": "^3.0", "mockery/mockery": "^1.5.1", - "orchestra/testbench-core": "^7.16", + "orchestra/testbench-core": "^8.0", "pda/pheanstalk": "^4.0", "phpstan/phpdoc-parser": "^1.15", "phpstan/phpstan": "^1.4.7", - "phpunit/phpunit": "^9.5.8", - "predis/predis": "^1.1.9|^2.0.2", - "symfony/cache": "^6.0", - "symfony/http-client": "^6.0" + "phpunit/phpunit": "^9.6.0 || ^10.0.7", + "predis/predis": "^2.0.2", + "symfony/cache": "^6.2", + "symfony/http-client": "^6.2.4" }, "suggest": { "ably/ably-php": "Required to use the Ably broadcast driver (^1.0).", "aws/aws-sdk-php": "Required to use the SQS queue driver, DynamoDb failed job storage, and SES mail driver (^3.235.5).", "brianium/paratest": "Required to run tests in parallel (^6.0).", - "doctrine/dbal": "Required to rename columns and drop SQLite columns (^2.13.3|^3.1.4).", + "doctrine/dbal": "Required to rename columns and drop SQLite columns (^3.5.1).", "ext-apcu": "Required to use the APC cache driver.", "ext-fileinfo": "Required to use the Filesystem class.", "ext-ftp": "Required to use the Flysystem FTP driver.", @@ -1966,20 +1968,20 @@ "nyholm/psr7": "Required to use PSR-7 bridging features (^1.2).", "pda/pheanstalk": "Required to use the beanstalk queue driver (^4.0).", "phpunit/phpunit": "Required to use assertions and run tests (^9.5.8).", - "predis/predis": "Required to use the predis connector (^1.1.9|^2.0.2).", + "predis/predis": "Required to use the predis connector (^2.0.2).", "psr/http-message": "Required to allow Storage::put to accept a StreamInterface (^1.0).", "pusher/pusher-php-server": "Required to use the Pusher broadcast driver (^6.0|^7.0).", - "symfony/cache": "Required to PSR-6 cache bridge (^6.0).", - "symfony/filesystem": "Required to enable support for relative symbolic links (^6.0).", - "symfony/http-client": "Required to enable support for the Symfony API mail transports (^6.0).", - "symfony/mailgun-mailer": "Required to enable support for the Mailgun mail transport (^6.0).", - "symfony/postmark-mailer": "Required to enable support for the Postmark mail transport (^6.0).", + "symfony/cache": "Required to PSR-6 cache bridge (^6.2).", + "symfony/filesystem": "Required to enable support for relative symbolic links (^6.2).", + "symfony/http-client": "Required to enable support for the Symfony API mail transports (^6.2).", + "symfony/mailgun-mailer": "Required to enable support for the Mailgun mail transport (^6.2).", + "symfony/postmark-mailer": "Required to enable support for the Postmark mail transport (^6.2).", "symfony/psr-http-message-bridge": "Required to use PSR-7 bridging features (^2.0)." }, "type": "library", "extra": { "branch-alias": { - "dev-master": "9.x-dev" + "dev-master": "10.x-dev" } }, "autoload": { @@ -2018,7 +2020,7 @@ "issues": "https://github.com/laravel/framework/issues", "source": "https://github.com/laravel/framework" }, - "time": "2023-02-14T14:51:14+00:00" + "time": "2023-02-16T22:03:27+00:00" }, { "name": "laravel/horizon", @@ -3137,42 +3139,41 @@ }, { "name": "monolog/monolog", - "version": "2.9.1", + "version": "3.3.1", "source": { "type": "git", "url": "https://github.com/Seldaek/monolog.git", - "reference": "f259e2b15fb95494c83f52d3caad003bbf5ffaa1" + "reference": "9b5daeaffce5b926cac47923798bba91059e60e2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Seldaek/monolog/zipball/f259e2b15fb95494c83f52d3caad003bbf5ffaa1", - "reference": "f259e2b15fb95494c83f52d3caad003bbf5ffaa1", + "url": "https://api.github.com/repos/Seldaek/monolog/zipball/9b5daeaffce5b926cac47923798bba91059e60e2", + "reference": "9b5daeaffce5b926cac47923798bba91059e60e2", "shasum": "" }, "require": { - "php": ">=7.2", - "psr/log": "^1.0.1 || ^2.0 || ^3.0" + "php": ">=8.1", + "psr/log": "^2.0 || ^3.0" }, "provide": { - "psr/log-implementation": "1.0.0 || 2.0.0 || 3.0.0" + "psr/log-implementation": "3.0.0" }, "require-dev": { - "aws/aws-sdk-php": "^2.4.9 || ^3.0", + "aws/aws-sdk-php": "^3.0", "doctrine/couchdb": "~1.0@dev", "elasticsearch/elasticsearch": "^7 || ^8", "ext-json": "*", "graylog2/gelf-php": "^1.4.2 || ^2@dev", - "guzzlehttp/guzzle": "^7.4", + "guzzlehttp/guzzle": "^7.4.5", "guzzlehttp/psr7": "^2.2", "mongodb/mongodb": "^1.8", "php-amqplib/php-amqplib": "~2.4 || ^3", - "phpspec/prophecy": "^1.15", - "phpstan/phpstan": "^0.12.91", - "phpunit/phpunit": "^8.5.14", - "predis/predis": "^1.1 || ^2.0", - "rollbar/rollbar": "^1.3 || ^2 || ^3", + "phpstan/phpstan": "^1.9", + "phpstan/phpstan-deprecation-rules": "^1.0", + "phpstan/phpstan-strict-rules": "^1.4", + "phpunit/phpunit": "^9.5.26", + "predis/predis": "^1.1 || ^2", "ruflin/elastica": "^7", - "swiftmailer/swiftmailer": "^5.3|^6.0", "symfony/mailer": "^5.4 || ^6", "symfony/mime": "^5.4 || ^6" }, @@ -3195,7 +3196,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "2.x-dev" + "dev-main": "3.x-dev" } }, "autoload": { @@ -3223,7 +3224,7 @@ ], "support": { "issues": "https://github.com/Seldaek/monolog/issues", - "source": "https://github.com/Seldaek/monolog/tree/2.9.1" + "source": "https://github.com/Seldaek/monolog/tree/3.3.1" }, "funding": [ { @@ -3235,7 +3236,7 @@ "type": "tidelift" } ], - "time": "2023-02-06T13:44:46+00:00" + "time": "2023-02-06T13:46:10+00:00" }, { "name": "mtdowling/jmespath.php", @@ -4431,20 +4432,20 @@ }, { "name": "ramsey/uuid", - "version": "4.x-dev", + "version": "4.7.3", "source": { "type": "git", "url": "https://github.com/ramsey/uuid.git", - "reference": "bf2bee216a4379eaf62162307d62bb7850405fec" + "reference": "433b2014e3979047db08a17a205f410ba3869cf2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/ramsey/uuid/zipball/bf2bee216a4379eaf62162307d62bb7850405fec", - "reference": "bf2bee216a4379eaf62162307d62bb7850405fec", + "url": "https://api.github.com/repos/ramsey/uuid/zipball/433b2014e3979047db08a17a205f410ba3869cf2", + "reference": "433b2014e3979047db08a17a205f410ba3869cf2", "shasum": "" }, "require": { - "brick/math": "^0.8.8 || ^0.9 || ^0.10 || ^0.11", + "brick/math": "^0.8.8 || ^0.9 || ^0.10", "ext-json": "*", "php": "^8.0", "ramsey/collection": "^1.2 || ^2.0" @@ -4481,7 +4482,6 @@ "paragonie/random-lib": "Provides RandomLib for use with the RandomLibAdapter", "ramsey/uuid-doctrine": "Allows the use of Ramsey\\Uuid\\Uuid as Doctrine field type." }, - "default-branch": true, "type": "library", "extra": { "captainhook": { @@ -4508,7 +4508,7 @@ ], "support": { "issues": "https://github.com/ramsey/uuid/issues", - "source": "https://github.com/ramsey/uuid/tree/4.x" + "source": "https://github.com/ramsey/uuid/tree/4.7.3" }, "funding": [ { @@ -4520,7 +4520,7 @@ "type": "tidelift" } ], - "time": "2023-02-07T16:14:23+00:00" + "time": "2023-01-12T18:13:24+00:00" }, { "name": "scrivo/highlight.php", @@ -8146,16 +8146,16 @@ }, { "name": "doctrine/dbal", - "version": "3.5.3", + "version": "3.6.0", "source": { "type": "git", "url": "https://github.com/doctrine/dbal.git", - "reference": "88fa7e5189fd5ec6682477044264dc0ed4e3aa1e" + "reference": "85b98cb23c8af471a67abfe14485da696bcabc2e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/dbal/zipball/88fa7e5189fd5ec6682477044264dc0ed4e3aa1e", - "reference": "88fa7e5189fd5ec6682477044264dc0ed4e3aa1e", + "url": "https://api.github.com/repos/doctrine/dbal/zipball/85b98cb23c8af471a67abfe14485da696bcabc2e", + "reference": "85b98cb23c8af471a67abfe14485da696bcabc2e", "shasum": "" }, "require": { @@ -8168,11 +8168,12 @@ "psr/log": "^1|^2|^3" }, "require-dev": { - "doctrine/coding-standard": "11.0.0", + "doctrine/coding-standard": "11.1.0", + "fig/log-test": "^1", "jetbrains/phpstorm-stubs": "2022.3", - "phpstan/phpstan": "1.9.4", + "phpstan/phpstan": "1.9.14", "phpstan/phpstan-strict-rules": "^1.4", - "phpunit/phpunit": "9.5.27", + "phpunit/phpunit": "9.6.3", "psalm/plugin-phpunit": "0.18.4", "squizlabs/php_codesniffer": "3.7.1", "symfony/cache": "^5.4|^6.0", @@ -8237,7 +8238,7 @@ ], "support": { "issues": "https://github.com/doctrine/dbal/issues", - "source": "https://github.com/doctrine/dbal/tree/3.5.3" + "source": "https://github.com/doctrine/dbal/tree/3.6.0" }, "funding": [ { @@ -8253,7 +8254,7 @@ "type": "tidelift" } ], - "time": "2023-01-12T10:21:44+00:00" + "time": "2023-02-07T22:52:03+00:00" }, { "name": "doctrine/deprecations", @@ -8389,76 +8390,6 @@ ], "time": "2022-10-12T20:59:15+00:00" }, - { - "name": "doctrine/instantiator", - "version": "2.0.0", - "source": { - "type": "git", - "url": "https://github.com/doctrine/instantiator.git", - "reference": "c6222283fa3f4ac679f8b9ced9a4e23f163e80d0" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/instantiator/zipball/c6222283fa3f4ac679f8b9ced9a4e23f163e80d0", - "reference": "c6222283fa3f4ac679f8b9ced9a4e23f163e80d0", - "shasum": "" - }, - "require": { - "php": "^8.1" - }, - "require-dev": { - "doctrine/coding-standard": "^11", - "ext-pdo": "*", - "ext-phar": "*", - "phpbench/phpbench": "^1.2", - "phpstan/phpstan": "^1.9.4", - "phpstan/phpstan-phpunit": "^1.3", - "phpunit/phpunit": "^9.5.27", - "vimeo/psalm": "^5.4" - }, - "type": "library", - "autoload": { - "psr-4": { - "Doctrine\\Instantiator\\": "src/Doctrine/Instantiator/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Marco Pivetta", - "email": "ocramius@gmail.com", - "homepage": "https://ocramius.github.io/" - } - ], - "description": "A small, lightweight utility to instantiate objects in PHP without invoking their constructors", - "homepage": "https://www.doctrine-project.org/projects/instantiator.html", - "keywords": [ - "constructor", - "instantiate" - ], - "support": { - "issues": "https://github.com/doctrine/instantiator/issues", - "source": "https://github.com/doctrine/instantiator/tree/2.0.0" - }, - "funding": [ - { - "url": "https://www.doctrine-project.org/sponsorship.html", - "type": "custom" - }, - { - "url": "https://www.patreon.com/phpdoctrine", - "type": "patreon" - }, - { - "url": "https://tidelift.com/funding/github/packagist/doctrine%2Finstantiator", - "type": "tidelift" - } - ], - "time": "2022-12-30T00:23:10+00:00" - }, { "name": "fakerphp/faker", "version": "v1.21.0", @@ -9261,38 +9192,38 @@ }, { "name": "nunomaduro/collision", - "version": "v6.4.0", + "version": "v7.0.3", "source": { "type": "git", "url": "https://github.com/nunomaduro/collision.git", - "reference": "f05978827b9343cba381ca05b8c7deee346b6015" + "reference": "fbf3c8a8ee08068bee7d81ee0cee5ddf032aaa84" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nunomaduro/collision/zipball/f05978827b9343cba381ca05b8c7deee346b6015", - "reference": "f05978827b9343cba381ca05b8c7deee346b6015", + "url": "https://api.github.com/repos/nunomaduro/collision/zipball/fbf3c8a8ee08068bee7d81ee0cee5ddf032aaa84", + "reference": "fbf3c8a8ee08068bee7d81ee0cee5ddf032aaa84", "shasum": "" }, "require": { - "filp/whoops": "^2.14.5", - "php": "^8.0.0", - "symfony/console": "^6.0.2" + "filp/whoops": "^2.14.6", + "nunomaduro/termwind": "^1.15.1", + "php": "^8.1.0", + "symfony/console": "^6.2.5" }, "require-dev": { - "brianium/paratest": "^6.4.1", - "laravel/framework": "^9.26.1", - "laravel/pint": "^1.1.1", - "nunomaduro/larastan": "^1.0.3", - "nunomaduro/mock-final-classes": "^1.1.0", - "orchestra/testbench": "^7.7", - "phpunit/phpunit": "^9.5.23", - "spatie/ignition": "^1.4.1" + "laravel/framework": "^10.0.0", + "laravel/pint": "^1.5.0", + "laravel/sail": "^1.20.2", + "laravel/sanctum": "^3.2.1", + "laravel/tinker": "^2.8.0", + "nunomaduro/larastan": "^2.4.0", + "orchestra/testbench-core": "^8.0.0", + "pestphp/pest": "^2.0.0", + "phpunit/phpunit": "^10.0.7", + "spatie/laravel-ignition": "^2.0.0" }, "type": "library", "extra": { - "branch-alias": { - "dev-develop": "6.x-dev" - }, "laravel": { "providers": [ "NunoMaduro\\Collision\\Adapters\\Laravel\\CollisionServiceProvider" @@ -9300,6 +9231,9 @@ } }, "autoload": { + "files": [ + "./src/Adapters/Phpunit/Autoload.php" + ], "psr-4": { "NunoMaduro\\Collision\\": "src/" } @@ -9345,7 +9279,7 @@ "type": "patreon" } ], - "time": "2023-01-03T12:54:54+00:00" + "time": "2023-02-16T14:34:30+00:00" }, { "name": "phar-io/manifest", @@ -9691,16 +9625,16 @@ }, { "name": "phpunit/php-code-coverage", - "version": "9.2.24", + "version": "10.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "2cf940ebc6355a9d430462811b5aaa308b174bed" + "reference": "bf4fbc9c13af7da12b3ea807574fb460f255daba" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/2cf940ebc6355a9d430462811b5aaa308b174bed", - "reference": "2cf940ebc6355a9d430462811b5aaa308b174bed", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/bf4fbc9c13af7da12b3ea807574fb460f255daba", + "reference": "bf4fbc9c13af7da12b3ea807574fb460f255daba", "shasum": "" }, "require": { @@ -9708,18 +9642,18 @@ "ext-libxml": "*", "ext-xmlwriter": "*", "nikic/php-parser": "^4.14", - "php": ">=7.3", - "phpunit/php-file-iterator": "^3.0.3", - "phpunit/php-text-template": "^2.0.2", - "sebastian/code-unit-reverse-lookup": "^2.0.2", - "sebastian/complexity": "^2.0", - "sebastian/environment": "^5.1.2", - "sebastian/lines-of-code": "^1.0.3", - "sebastian/version": "^3.0.1", + "php": ">=8.1", + "phpunit/php-file-iterator": "^4.0", + "phpunit/php-text-template": "^3.0", + "sebastian/code-unit-reverse-lookup": "^3.0", + "sebastian/complexity": "^3.0", + "sebastian/environment": "^6.0", + "sebastian/lines-of-code": "^2.0", + "sebastian/version": "^4.0", "theseer/tokenizer": "^1.2.0" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^10.0" }, "suggest": { "ext-pcov": "*", @@ -9728,7 +9662,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "9.2-dev" + "dev-main": "10.0-dev" } }, "autoload": { @@ -9756,7 +9690,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", - "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.24" + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/10.0.0" }, "funding": [ { @@ -9764,32 +9698,32 @@ "type": "github" } ], - "time": "2023-01-26T08:26:55+00:00" + "time": "2023-02-03T07:14:34+00:00" }, { "name": "phpunit/php-file-iterator", - "version": "3.0.6", + "version": "4.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-file-iterator.git", - "reference": "cf1c2e7c203ac650e352f4cc675a7021e7d1b3cf" + "reference": "fd9329ab3368f59fe1fe808a189c51086bd4b6bd" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/cf1c2e7c203ac650e352f4cc675a7021e7d1b3cf", - "reference": "cf1c2e7c203ac650e352f4cc675a7021e7d1b3cf", + "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/fd9329ab3368f59fe1fe808a189c51086bd4b6bd", + "reference": "fd9329ab3368f59fe1fe808a189c51086bd4b6bd", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.1" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-main": "4.0-dev" } }, "autoload": { @@ -9816,7 +9750,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-file-iterator/issues", - "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/3.0.6" + "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/4.0.1" }, "funding": [ { @@ -9824,28 +9758,28 @@ "type": "github" } ], - "time": "2021-12-02T12:48:52+00:00" + "time": "2023-02-10T16:53:14+00:00" }, { "name": "phpunit/php-invoker", - "version": "3.1.1", + "version": "4.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-invoker.git", - "reference": "5a10147d0aaf65b58940a0b72f71c9ac0423cc67" + "reference": "f5e568ba02fa5ba0ddd0f618391d5a9ea50b06d7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-invoker/zipball/5a10147d0aaf65b58940a0b72f71c9ac0423cc67", - "reference": "5a10147d0aaf65b58940a0b72f71c9ac0423cc67", + "url": "https://api.github.com/repos/sebastianbergmann/php-invoker/zipball/f5e568ba02fa5ba0ddd0f618391d5a9ea50b06d7", + "reference": "f5e568ba02fa5ba0ddd0f618391d5a9ea50b06d7", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.1" }, "require-dev": { "ext-pcntl": "*", - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^10.0" }, "suggest": { "ext-pcntl": "*" @@ -9853,7 +9787,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.1-dev" + "dev-main": "4.0-dev" } }, "autoload": { @@ -9879,7 +9813,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-invoker/issues", - "source": "https://github.com/sebastianbergmann/php-invoker/tree/3.1.1" + "source": "https://github.com/sebastianbergmann/php-invoker/tree/4.0.0" }, "funding": [ { @@ -9887,32 +9821,32 @@ "type": "github" } ], - "time": "2020-09-28T05:58:55+00:00" + "time": "2023-02-03T06:56:09+00:00" }, { "name": "phpunit/php-text-template", - "version": "2.0.4", + "version": "3.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-text-template.git", - "reference": "5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28" + "reference": "9f3d3709577a527025f55bcf0f7ab8052c8bb37d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28", - "reference": "5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28", + "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/9f3d3709577a527025f55bcf0f7ab8052c8bb37d", + "reference": "9f3d3709577a527025f55bcf0f7ab8052c8bb37d", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.1" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0-dev" + "dev-main": "3.0-dev" } }, "autoload": { @@ -9938,7 +9872,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-text-template/issues", - "source": "https://github.com/sebastianbergmann/php-text-template/tree/2.0.4" + "source": "https://github.com/sebastianbergmann/php-text-template/tree/3.0.0" }, "funding": [ { @@ -9946,32 +9880,32 @@ "type": "github" } ], - "time": "2020-10-26T05:33:50+00:00" + "time": "2023-02-03T06:56:46+00:00" }, { "name": "phpunit/php-timer", - "version": "5.0.3", + "version": "6.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-timer.git", - "reference": "5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2" + "reference": "e2a2d67966e740530f4a3343fe2e030ffdc1161d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2", - "reference": "5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2", + "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/e2a2d67966e740530f4a3343fe2e030ffdc1161d", + "reference": "e2a2d67966e740530f4a3343fe2e030ffdc1161d", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.1" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "5.0-dev" + "dev-main": "6.0-dev" } }, "autoload": { @@ -9997,7 +9931,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-timer/issues", - "source": "https://github.com/sebastianbergmann/php-timer/tree/5.0.3" + "source": "https://github.com/sebastianbergmann/php-timer/tree/6.0.0" }, "funding": [ { @@ -10005,24 +9939,23 @@ "type": "github" } ], - "time": "2020-10-26T13:16:10+00:00" + "time": "2023-02-03T06:57:52+00:00" }, { "name": "phpunit/phpunit", - "version": "9.6.3", + "version": "10.0.7", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "e7b1615e3e887d6c719121c6d4a44b0ab9645555" + "reference": "a6f61c5629dd95db79af72f1e94d56702187479a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/e7b1615e3e887d6c719121c6d4a44b0ab9645555", - "reference": "e7b1615e3e887d6c719121c6d4a44b0ab9645555", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/a6f61c5629dd95db79af72f1e94d56702187479a", + "reference": "a6f61c5629dd95db79af72f1e94d56702187479a", "shasum": "" }, "require": { - "doctrine/instantiator": "^1.3.1 || ^2", "ext-dom": "*", "ext-json": "*", "ext-libxml": "*", @@ -10032,27 +9965,26 @@ "myclabs/deep-copy": "^1.10.1", "phar-io/manifest": "^2.0.3", "phar-io/version": "^3.0.2", - "php": ">=7.3", - "phpunit/php-code-coverage": "^9.2.13", - "phpunit/php-file-iterator": "^3.0.5", - "phpunit/php-invoker": "^3.1.1", - "phpunit/php-text-template": "^2.0.3", - "phpunit/php-timer": "^5.0.2", - "sebastian/cli-parser": "^1.0.1", - "sebastian/code-unit": "^1.0.6", - "sebastian/comparator": "^4.0.8", - "sebastian/diff": "^4.0.3", - "sebastian/environment": "^5.1.3", - "sebastian/exporter": "^4.0.5", - "sebastian/global-state": "^5.0.1", - "sebastian/object-enumerator": "^4.0.3", - "sebastian/resource-operations": "^3.0.3", - "sebastian/type": "^3.2", - "sebastian/version": "^3.0.2" + "php": ">=8.1", + "phpunit/php-code-coverage": "^10.0", + "phpunit/php-file-iterator": "^4.0", + "phpunit/php-invoker": "^4.0", + "phpunit/php-text-template": "^3.0", + "phpunit/php-timer": "^6.0", + "sebastian/cli-parser": "^2.0", + "sebastian/code-unit": "^2.0", + "sebastian/comparator": "^5.0", + "sebastian/diff": "^5.0", + "sebastian/environment": "^6.0", + "sebastian/exporter": "^5.0", + "sebastian/global-state": "^6.0", + "sebastian/object-enumerator": "^5.0", + "sebastian/recursion-context": "^5.0", + "sebastian/type": "^4.0", + "sebastian/version": "^4.0" }, "suggest": { - "ext-soap": "*", - "ext-xdebug": "*" + "ext-soap": "*" }, "bin": [ "phpunit" @@ -10060,7 +9992,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "9.6-dev" + "dev-main": "10.0-dev" } }, "autoload": { @@ -10091,7 +10023,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", - "source": "https://github.com/sebastianbergmann/phpunit/tree/9.6.3" + "source": "https://github.com/sebastianbergmann/phpunit/tree/10.0.7" }, "funding": [ { @@ -10107,7 +10039,7 @@ "type": "tidelift" } ], - "time": "2023-02-04T13:37:15+00:00" + "time": "2023-02-08T15:16:31+00:00" }, { "name": "pimple/pimple", @@ -10213,28 +10145,28 @@ }, { "name": "sebastian/cli-parser", - "version": "1.0.1", + "version": "2.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/cli-parser.git", - "reference": "442e7c7e687e42adc03470c7b668bc4b2402c0b2" + "reference": "efdc130dbbbb8ef0b545a994fd811725c5282cae" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/442e7c7e687e42adc03470c7b668bc4b2402c0b2", - "reference": "442e7c7e687e42adc03470c7b668bc4b2402c0b2", + "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/efdc130dbbbb8ef0b545a994fd811725c5282cae", + "reference": "efdc130dbbbb8ef0b545a994fd811725c5282cae", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.1" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0-dev" + "dev-main": "2.0-dev" } }, "autoload": { @@ -10257,7 +10189,7 @@ "homepage": "https://github.com/sebastianbergmann/cli-parser", "support": { "issues": "https://github.com/sebastianbergmann/cli-parser/issues", - "source": "https://github.com/sebastianbergmann/cli-parser/tree/1.0.1" + "source": "https://github.com/sebastianbergmann/cli-parser/tree/2.0.0" }, "funding": [ { @@ -10265,32 +10197,32 @@ "type": "github" } ], - "time": "2020-09-28T06:08:49+00:00" + "time": "2023-02-03T06:58:15+00:00" }, { "name": "sebastian/code-unit", - "version": "1.0.8", + "version": "2.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/code-unit.git", - "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120" + "reference": "a81fee9eef0b7a76af11d121767abc44c104e503" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/code-unit/zipball/1fc9f64c0927627ef78ba436c9b17d967e68e120", - "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit/zipball/a81fee9eef0b7a76af11d121767abc44c104e503", + "reference": "a81fee9eef0b7a76af11d121767abc44c104e503", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.1" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0-dev" + "dev-main": "2.0-dev" } }, "autoload": { @@ -10313,7 +10245,7 @@ "homepage": "https://github.com/sebastianbergmann/code-unit", "support": { "issues": "https://github.com/sebastianbergmann/code-unit/issues", - "source": "https://github.com/sebastianbergmann/code-unit/tree/1.0.8" + "source": "https://github.com/sebastianbergmann/code-unit/tree/2.0.0" }, "funding": [ { @@ -10321,32 +10253,32 @@ "type": "github" } ], - "time": "2020-10-26T13:08:54+00:00" + "time": "2023-02-03T06:58:43+00:00" }, { "name": "sebastian/code-unit-reverse-lookup", - "version": "2.0.3", + "version": "3.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", - "reference": "ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5" + "reference": "5e3a687f7d8ae33fb362c5c0743794bbb2420a1d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5", - "reference": "ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/5e3a687f7d8ae33fb362c5c0743794bbb2420a1d", + "reference": "5e3a687f7d8ae33fb362c5c0743794bbb2420a1d", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.1" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0-dev" + "dev-main": "3.0-dev" } }, "autoload": { @@ -10368,7 +10300,7 @@ "homepage": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/", "support": { "issues": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/issues", - "source": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/tree/2.0.3" + "source": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/tree/3.0.0" }, "funding": [ { @@ -10376,34 +10308,36 @@ "type": "github" } ], - "time": "2020-09-28T05:30:19+00:00" + "time": "2023-02-03T06:59:15+00:00" }, { "name": "sebastian/comparator", - "version": "4.0.8", + "version": "5.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/comparator.git", - "reference": "fa0f136dd2334583309d32b62544682ee972b51a" + "reference": "72f01e6586e0caf6af81297897bd112eb7e9627c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/fa0f136dd2334583309d32b62544682ee972b51a", - "reference": "fa0f136dd2334583309d32b62544682ee972b51a", + "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/72f01e6586e0caf6af81297897bd112eb7e9627c", + "reference": "72f01e6586e0caf6af81297897bd112eb7e9627c", "shasum": "" }, "require": { - "php": ">=7.3", - "sebastian/diff": "^4.0", - "sebastian/exporter": "^4.0" + "ext-dom": "*", + "ext-mbstring": "*", + "php": ">=8.1", + "sebastian/diff": "^5.0", + "sebastian/exporter": "^5.0" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "4.0-dev" + "dev-main": "5.0-dev" } }, "autoload": { @@ -10442,7 +10376,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/comparator/issues", - "source": "https://github.com/sebastianbergmann/comparator/tree/4.0.8" + "source": "https://github.com/sebastianbergmann/comparator/tree/5.0.0" }, "funding": [ { @@ -10450,33 +10384,33 @@ "type": "github" } ], - "time": "2022-09-14T12:41:17+00:00" + "time": "2023-02-03T07:07:16+00:00" }, { "name": "sebastian/complexity", - "version": "2.0.2", + "version": "3.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/complexity.git", - "reference": "739b35e53379900cc9ac327b2147867b8b6efd88" + "reference": "e67d240970c9dc7ea7b2123a6d520e334dd61dc6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/739b35e53379900cc9ac327b2147867b8b6efd88", - "reference": "739b35e53379900cc9ac327b2147867b8b6efd88", + "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/e67d240970c9dc7ea7b2123a6d520e334dd61dc6", + "reference": "e67d240970c9dc7ea7b2123a6d520e334dd61dc6", "shasum": "" }, "require": { - "nikic/php-parser": "^4.7", - "php": ">=7.3" + "nikic/php-parser": "^4.10", + "php": ">=8.1" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0-dev" + "dev-main": "3.0-dev" } }, "autoload": { @@ -10499,7 +10433,7 @@ "homepage": "https://github.com/sebastianbergmann/complexity", "support": { "issues": "https://github.com/sebastianbergmann/complexity/issues", - "source": "https://github.com/sebastianbergmann/complexity/tree/2.0.2" + "source": "https://github.com/sebastianbergmann/complexity/tree/3.0.0" }, "funding": [ { @@ -10507,33 +10441,33 @@ "type": "github" } ], - "time": "2020-10-26T15:52:27+00:00" + "time": "2023-02-03T06:59:47+00:00" }, { "name": "sebastian/diff", - "version": "4.0.4", + "version": "5.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "3461e3fccc7cfdfc2720be910d3bd73c69be590d" + "reference": "70dd1b20bc198da394ad542e988381b44e64e39f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/3461e3fccc7cfdfc2720be910d3bd73c69be590d", - "reference": "3461e3fccc7cfdfc2720be910d3bd73c69be590d", + "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/70dd1b20bc198da394ad542e988381b44e64e39f", + "reference": "70dd1b20bc198da394ad542e988381b44e64e39f", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.1" }, "require-dev": { - "phpunit/phpunit": "^9.3", + "phpunit/phpunit": "^10.0", "symfony/process": "^4.2 || ^5" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "4.0-dev" + "dev-main": "5.0-dev" } }, "autoload": { @@ -10565,7 +10499,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/diff/issues", - "source": "https://github.com/sebastianbergmann/diff/tree/4.0.4" + "source": "https://github.com/sebastianbergmann/diff/tree/5.0.0" }, "funding": [ { @@ -10573,27 +10507,27 @@ "type": "github" } ], - "time": "2020-10-26T13:10:38+00:00" + "time": "2023-02-03T07:00:31+00:00" }, { "name": "sebastian/environment", - "version": "5.1.5", + "version": "6.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "830c43a844f1f8d5b7a1f6d6076b784454d8b7ed" + "reference": "b6f3694c6386c7959915a0037652e0c40f6f69cc" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/830c43a844f1f8d5b7a1f6d6076b784454d8b7ed", - "reference": "830c43a844f1f8d5b7a1f6d6076b784454d8b7ed", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/b6f3694c6386c7959915a0037652e0c40f6f69cc", + "reference": "b6f3694c6386c7959915a0037652e0c40f6f69cc", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.1" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^10.0" }, "suggest": { "ext-posix": "*" @@ -10601,7 +10535,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "5.1-dev" + "dev-main": "6.0-dev" } }, "autoload": { @@ -10620,7 +10554,7 @@ } ], "description": "Provides functionality to handle HHVM/PHP environments", - "homepage": "http://www.github.com/sebastianbergmann/environment", + "homepage": "https://github.com/sebastianbergmann/environment", "keywords": [ "Xdebug", "environment", @@ -10628,7 +10562,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/environment/issues", - "source": "https://github.com/sebastianbergmann/environment/tree/5.1.5" + "source": "https://github.com/sebastianbergmann/environment/tree/6.0.0" }, "funding": [ { @@ -10636,34 +10570,34 @@ "type": "github" } ], - "time": "2023-02-03T06:03:51+00:00" + "time": "2023-02-03T07:03:04+00:00" }, { "name": "sebastian/exporter", - "version": "4.0.5", + "version": "5.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "ac230ed27f0f98f597c8a2b6eb7ac563af5e5b9d" + "reference": "f3ec4bf931c0b31e5b413f5b4fc970a7d03338c0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/ac230ed27f0f98f597c8a2b6eb7ac563af5e5b9d", - "reference": "ac230ed27f0f98f597c8a2b6eb7ac563af5e5b9d", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/f3ec4bf931c0b31e5b413f5b4fc970a7d03338c0", + "reference": "f3ec4bf931c0b31e5b413f5b4fc970a7d03338c0", "shasum": "" }, "require": { - "php": ">=7.3", - "sebastian/recursion-context": "^4.0" + "ext-mbstring": "*", + "php": ">=8.1", + "sebastian/recursion-context": "^5.0" }, "require-dev": { - "ext-mbstring": "*", - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "4.0-dev" + "dev-main": "5.0-dev" } }, "autoload": { @@ -10705,7 +10639,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/exporter/issues", - "source": "https://github.com/sebastianbergmann/exporter/tree/4.0.5" + "source": "https://github.com/sebastianbergmann/exporter/tree/5.0.0" }, "funding": [ { @@ -10713,38 +10647,35 @@ "type": "github" } ], - "time": "2022-09-14T06:03:37+00:00" + "time": "2023-02-03T07:06:49+00:00" }, { "name": "sebastian/global-state", - "version": "5.0.5", + "version": "6.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/global-state.git", - "reference": "0ca8db5a5fc9c8646244e629625ac486fa286bf2" + "reference": "aab257c712de87b90194febd52e4d184551c2d44" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/0ca8db5a5fc9c8646244e629625ac486fa286bf2", - "reference": "0ca8db5a5fc9c8646244e629625ac486fa286bf2", + "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/aab257c712de87b90194febd52e4d184551c2d44", + "reference": "aab257c712de87b90194febd52e4d184551c2d44", "shasum": "" }, "require": { - "php": ">=7.3", - "sebastian/object-reflector": "^2.0", - "sebastian/recursion-context": "^4.0" + "php": ">=8.1", + "sebastian/object-reflector": "^3.0", + "sebastian/recursion-context": "^5.0" }, "require-dev": { "ext-dom": "*", - "phpunit/phpunit": "^9.3" - }, - "suggest": { - "ext-uopz": "*" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "5.0-dev" + "dev-main": "6.0-dev" } }, "autoload": { @@ -10769,7 +10700,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/global-state/issues", - "source": "https://github.com/sebastianbergmann/global-state/tree/5.0.5" + "source": "https://github.com/sebastianbergmann/global-state/tree/6.0.0" }, "funding": [ { @@ -10777,33 +10708,33 @@ "type": "github" } ], - "time": "2022-02-14T08:28:10+00:00" + "time": "2023-02-03T07:07:38+00:00" }, { "name": "sebastian/lines-of-code", - "version": "1.0.3", + "version": "2.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/lines-of-code.git", - "reference": "c1c2e997aa3146983ed888ad08b15470a2e22ecc" + "reference": "17c4d940ecafb3d15d2cf916f4108f664e28b130" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/c1c2e997aa3146983ed888ad08b15470a2e22ecc", - "reference": "c1c2e997aa3146983ed888ad08b15470a2e22ecc", + "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/17c4d940ecafb3d15d2cf916f4108f664e28b130", + "reference": "17c4d940ecafb3d15d2cf916f4108f664e28b130", "shasum": "" }, "require": { - "nikic/php-parser": "^4.6", - "php": ">=7.3" + "nikic/php-parser": "^4.10", + "php": ">=8.1" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0-dev" + "dev-main": "2.0-dev" } }, "autoload": { @@ -10826,7 +10757,7 @@ "homepage": "https://github.com/sebastianbergmann/lines-of-code", "support": { "issues": "https://github.com/sebastianbergmann/lines-of-code/issues", - "source": "https://github.com/sebastianbergmann/lines-of-code/tree/1.0.3" + "source": "https://github.com/sebastianbergmann/lines-of-code/tree/2.0.0" }, "funding": [ { @@ -10834,34 +10765,34 @@ "type": "github" } ], - "time": "2020-11-28T06:42:11+00:00" + "time": "2023-02-03T07:08:02+00:00" }, { "name": "sebastian/object-enumerator", - "version": "4.0.4", + "version": "5.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/object-enumerator.git", - "reference": "5c9eeac41b290a3712d88851518825ad78f45c71" + "reference": "202d0e344a580d7f7d04b3fafce6933e59dae906" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/5c9eeac41b290a3712d88851518825ad78f45c71", - "reference": "5c9eeac41b290a3712d88851518825ad78f45c71", + "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/202d0e344a580d7f7d04b3fafce6933e59dae906", + "reference": "202d0e344a580d7f7d04b3fafce6933e59dae906", "shasum": "" }, "require": { - "php": ">=7.3", - "sebastian/object-reflector": "^2.0", - "sebastian/recursion-context": "^4.0" + "php": ">=8.1", + "sebastian/object-reflector": "^3.0", + "sebastian/recursion-context": "^5.0" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "4.0-dev" + "dev-main": "5.0-dev" } }, "autoload": { @@ -10883,7 +10814,7 @@ "homepage": "https://github.com/sebastianbergmann/object-enumerator/", "support": { "issues": "https://github.com/sebastianbergmann/object-enumerator/issues", - "source": "https://github.com/sebastianbergmann/object-enumerator/tree/4.0.4" + "source": "https://github.com/sebastianbergmann/object-enumerator/tree/5.0.0" }, "funding": [ { @@ -10891,32 +10822,32 @@ "type": "github" } ], - "time": "2020-10-26T13:12:34+00:00" + "time": "2023-02-03T07:08:32+00:00" }, { "name": "sebastian/object-reflector", - "version": "2.0.4", + "version": "3.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/object-reflector.git", - "reference": "b4f479ebdbf63ac605d183ece17d8d7fe49c15c7" + "reference": "24ed13d98130f0e7122df55d06c5c4942a577957" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/b4f479ebdbf63ac605d183ece17d8d7fe49c15c7", - "reference": "b4f479ebdbf63ac605d183ece17d8d7fe49c15c7", + "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/24ed13d98130f0e7122df55d06c5c4942a577957", + "reference": "24ed13d98130f0e7122df55d06c5c4942a577957", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.1" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0-dev" + "dev-main": "3.0-dev" } }, "autoload": { @@ -10938,7 +10869,7 @@ "homepage": "https://github.com/sebastianbergmann/object-reflector/", "support": { "issues": "https://github.com/sebastianbergmann/object-reflector/issues", - "source": "https://github.com/sebastianbergmann/object-reflector/tree/2.0.4" + "source": "https://github.com/sebastianbergmann/object-reflector/tree/3.0.0" }, "funding": [ { @@ -10946,32 +10877,32 @@ "type": "github" } ], - "time": "2020-10-26T13:14:26+00:00" + "time": "2023-02-03T07:06:18+00:00" }, { "name": "sebastian/recursion-context", - "version": "4.0.5", + "version": "5.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/recursion-context.git", - "reference": "e75bd0f07204fec2a0af9b0f3cfe97d05f92efc1" + "reference": "05909fb5bc7df4c52992396d0116aed689f93712" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/e75bd0f07204fec2a0af9b0f3cfe97d05f92efc1", - "reference": "e75bd0f07204fec2a0af9b0f3cfe97d05f92efc1", + "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/05909fb5bc7df4c52992396d0116aed689f93712", + "reference": "05909fb5bc7df4c52992396d0116aed689f93712", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.1" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "4.0-dev" + "dev-main": "5.0-dev" } }, "autoload": { @@ -11001,7 +10932,7 @@ "homepage": "https://github.com/sebastianbergmann/recursion-context", "support": { "issues": "https://github.com/sebastianbergmann/recursion-context/issues", - "source": "https://github.com/sebastianbergmann/recursion-context/tree/4.0.5" + "source": "https://github.com/sebastianbergmann/recursion-context/tree/5.0.0" }, "funding": [ { @@ -11009,87 +10940,32 @@ "type": "github" } ], - "time": "2023-02-03T06:07:39+00:00" - }, - { - "name": "sebastian/resource-operations", - "version": "3.0.3", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/resource-operations.git", - "reference": "0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8", - "reference": "0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8", - "shasum": "" - }, - "require": { - "php": ">=7.3" - }, - "require-dev": { - "phpunit/phpunit": "^9.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.0-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Provides a list of PHP built-in functions that operate on resources", - "homepage": "https://www.github.com/sebastianbergmann/resource-operations", - "support": { - "issues": "https://github.com/sebastianbergmann/resource-operations/issues", - "source": "https://github.com/sebastianbergmann/resource-operations/tree/3.0.3" - }, - "funding": [ - { - "url": "https://github.com/sebastianbergmann", - "type": "github" - } - ], - "time": "2020-09-28T06:45:17+00:00" + "time": "2023-02-03T07:05:40+00:00" }, { "name": "sebastian/type", - "version": "3.2.1", + "version": "4.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/type.git", - "reference": "75e2c2a32f5e0b3aef905b9ed0b179b953b3d7c7" + "reference": "462699a16464c3944eefc02ebdd77882bd3925bf" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/75e2c2a32f5e0b3aef905b9ed0b179b953b3d7c7", - "reference": "75e2c2a32f5e0b3aef905b9ed0b179b953b3d7c7", + "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/462699a16464c3944eefc02ebdd77882bd3925bf", + "reference": "462699a16464c3944eefc02ebdd77882bd3925bf", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.1" }, "require-dev": { - "phpunit/phpunit": "^9.5" + "phpunit/phpunit": "^10.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.2-dev" + "dev-main": "4.0-dev" } }, "autoload": { @@ -11112,7 +10988,7 @@ "homepage": "https://github.com/sebastianbergmann/type", "support": { "issues": "https://github.com/sebastianbergmann/type/issues", - "source": "https://github.com/sebastianbergmann/type/tree/3.2.1" + "source": "https://github.com/sebastianbergmann/type/tree/4.0.0" }, "funding": [ { @@ -11120,29 +10996,29 @@ "type": "github" } ], - "time": "2023-02-03T06:13:03+00:00" + "time": "2023-02-03T07:10:45+00:00" }, { "name": "sebastian/version", - "version": "3.0.2", + "version": "4.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/version.git", - "reference": "c6c1022351a901512170118436c764e473f6de8c" + "reference": "c51fa83a5d8f43f1402e3f32a005e6262244ef17" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/c6c1022351a901512170118436c764e473f6de8c", - "reference": "c6c1022351a901512170118436c764e473f6de8c", + "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/c51fa83a5d8f43f1402e3f32a005e6262244ef17", + "reference": "c51fa83a5d8f43f1402e3f32a005e6262244ef17", "shasum": "" }, "require": { - "php": ">=7.3" + "php": ">=8.1" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-main": "4.0-dev" } }, "autoload": { @@ -11165,7 +11041,7 @@ "homepage": "https://github.com/sebastianbergmann/version", "support": { "issues": "https://github.com/sebastianbergmann/version/issues", - "source": "https://github.com/sebastianbergmann/version/tree/3.0.2" + "source": "https://github.com/sebastianbergmann/version/tree/4.0.1" }, "funding": [ { @@ -11173,7 +11049,7 @@ "type": "github" } ], - "time": "2020-09-28T06:39:44+00:00" + "time": "2023-02-07T11:34:05+00:00" }, { "name": "spatie/array-to-xml", @@ -11446,41 +11322,37 @@ }, { "name": "spatie/laravel-ignition", - "version": "1.6.4", + "version": "2.0.0", "source": { "type": "git", "url": "https://github.com/spatie/laravel-ignition.git", - "reference": "1a2b4bd3d48c72526c0ba417687e5c56b5cf49bc" + "reference": "70c0e2a22c5c4b691a34db8c98bd6d695660a97a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/spatie/laravel-ignition/zipball/1a2b4bd3d48c72526c0ba417687e5c56b5cf49bc", - "reference": "1a2b4bd3d48c72526c0ba417687e5c56b5cf49bc", + "url": "https://api.github.com/repos/spatie/laravel-ignition/zipball/70c0e2a22c5c4b691a34db8c98bd6d695660a97a", + "reference": "70c0e2a22c5c4b691a34db8c98bd6d695660a97a", "shasum": "" }, "require": { "ext-curl": "*", "ext-json": "*", "ext-mbstring": "*", - "illuminate/support": "^8.77|^9.27", - "monolog/monolog": "^2.3", - "php": "^8.0", - "spatie/flare-client-php": "^1.0.1", - "spatie/ignition": "^1.4.1", - "symfony/console": "^5.0|^6.0", - "symfony/var-dumper": "^5.0|^6.0" + "illuminate/support": "^10.0", + "php": "^8.1", + "spatie/flare-client-php": "^1.3.5", + "spatie/ignition": "^1.4.3", + "symfony/console": "^6.2.3", + "symfony/var-dumper": "^6.2.3" }, "require-dev": { - "filp/whoops": "^2.14", - "livewire/livewire": "^2.8|dev-develop", - "mockery/mockery": "^1.4", - "nunomaduro/larastan": "^1.0", - "orchestra/testbench": "^6.23|^7.0", - "pestphp/pest": "^1.20", - "phpstan/extension-installer": "^1.1", - "phpstan/phpstan-deprecation-rules": "^1.0", - "phpstan/phpstan-phpunit": "^1.0", - "spatie/laravel-ray": "^1.27" + "livewire/livewire": "^2.11", + "mockery/mockery": "^1.5.1", + "orchestra/testbench": "^8.0", + "pestphp/pest": "^1.22.3", + "phpstan/extension-installer": "^1.2", + "phpstan/phpstan-deprecation-rules": "^1.1.1", + "phpstan/phpstan-phpunit": "^1.3.3" }, "type": "library", "extra": { @@ -11491,6 +11363,9 @@ "aliases": { "Flare": "Spatie\\LaravelIgnition\\Facades\\Flare" } + }, + "branch-alias": { + "dev-main": "2.0-dev" } }, "autoload": { @@ -11532,7 +11407,7 @@ "type": "github" } ], - "time": "2023-01-03T19:28:04+00:00" + "time": "2023-01-24T07:20:39+00:00" }, { "name": "spatie/laravel-ray", @@ -11671,16 +11546,16 @@ }, { "name": "spatie/ray", - "version": "1.36.0", + "version": "1.36.2", "source": { "type": "git", "url": "https://github.com/spatie/ray.git", - "reference": "4a4def8cda4806218341b8204c98375aa8c34323" + "reference": "71dfde21900447ab37698fc07ff28b7f1e1822b8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/spatie/ray/zipball/4a4def8cda4806218341b8204c98375aa8c34323", - "reference": "4a4def8cda4806218341b8204c98375aa8c34323", + "url": "https://api.github.com/repos/spatie/ray/zipball/71dfde21900447ab37698fc07ff28b7f1e1822b8", + "reference": "71dfde21900447ab37698fc07ff28b7f1e1822b8", "shasum": "" }, "require": { @@ -11695,7 +11570,8 @@ }, "require-dev": { "illuminate/support": "6.x|^8.18|^9.0", - "nesbot/carbon": "^2.43", + "nesbot/carbon": "^2.63", + "pestphp/pest": "^1.22", "phpstan/phpstan": "^0.12.92", "phpunit/phpunit": "^9.5", "spatie/phpunit-snapshot-assertions": "^4.2", @@ -11730,7 +11606,7 @@ ], "support": { "issues": "https://github.com/spatie/ray/issues", - "source": "https://github.com/spatie/ray/tree/1.36.0" + "source": "https://github.com/spatie/ray/tree/1.36.2" }, "funding": [ { @@ -11742,7 +11618,7 @@ "type": "other" } ], - "time": "2022-08-11T14:04:18+00:00" + "time": "2023-02-10T09:24:13+00:00" }, { "name": "symfony/filesystem", @@ -12182,16 +12058,16 @@ }, { "name": "zbateson/mail-mime-parser", - "version": "2.3.0", + "version": "2.4.0", "source": { "type": "git", "url": "https://github.com/zbateson/mail-mime-parser.git", - "reference": "d59e0c5eeb1442fca94bcb3b9d3c6be66318a500" + "reference": "20b3e48eb799537683780bc8782fbbe9bc25934a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/zbateson/mail-mime-parser/zipball/d59e0c5eeb1442fca94bcb3b9d3c6be66318a500", - "reference": "d59e0c5eeb1442fca94bcb3b9d3c6be66318a500", + "url": "https://api.github.com/repos/zbateson/mail-mime-parser/zipball/20b3e48eb799537683780bc8782fbbe9bc25934a", + "reference": "20b3e48eb799537683780bc8782fbbe9bc25934a", "shasum": "" }, "require": { @@ -12253,7 +12129,7 @@ "type": "github" } ], - "time": "2023-01-30T19:04:55+00:00" + "time": "2023-02-14T22:58:03+00:00" }, { "name": "zbateson/mb-wrapper", @@ -12389,8 +12265,10 @@ } ], "aliases": [], - "minimum-stability": "dev", - "stability-flags": [], + "minimum-stability": "stable", + "stability-flags": { + "jublonet/codebird-php": 10 + }, "prefer-stable": true, "prefer-lowest": false, "platform": { diff --git a/config/app.php b/config/app.php index 26a66d9a..0c0fd785 100644 --- a/config/app.php +++ b/config/app.php @@ -63,7 +63,7 @@ return [ | Application Long URL |-------------------------------------------------------------------------- | - | The short URL for the application + | The long URL for the application | */ @@ -191,7 +191,9 @@ return [ |-------------------------------------------------------------------------- | Font Link |-------------------------------------------------------------------------- + | | Which URL should the app load custom fonts from + | */ 'font_link' => env('FONT_LINK'), diff --git a/config/auth.php b/config/auth.php index d8c6cee7..cae00280 100644 --- a/config/auth.php +++ b/config/auth.php @@ -84,12 +84,16 @@ return [ | considered valid. This security feature keeps tokens short-lived so | they have less time to be guessed. You may change this as needed. | + | The throttle setting is the number of seconds a user must wait before + | generating more password reset tokens. This prevents the user from + | quickly generating a very large amount of password reset tokens. + | */ 'passwords' => [ 'users' => [ 'provider' => 'users', - 'table' => 'password_resets', + 'table' => 'password_reset_tokens', 'expire' => 60, 'throttle' => 60, ], diff --git a/config/mail.php b/config/mail.php index 534395a3..542d98c3 100644 --- a/config/mail.php +++ b/config/mail.php @@ -28,7 +28,7 @@ return [ | sending an e-mail. You will specify which one you are using for your | mailers below. You are free to add additional mailers as required. | - | Supported: "smtp", "sendmail", "mailgun", "ses", + | Supported: "smtp", "sendmail", "mailgun", "ses", "ses-v2", | "postmark", "log", "array", "failover" | */ @@ -51,10 +51,16 @@ return [ 'mailgun' => [ 'transport' => 'mailgun', + // 'client' => [ + // 'timeout' => 5, + // ], ], 'postmark' => [ 'transport' => 'postmark', + // 'client' => [ + // 'timeout' => 5, + // ], ], 'sendmail' => [ diff --git a/database/factories/ArticleFactory.php b/database/factories/ArticleFactory.php index 2b69f126..7695e27e 100644 --- a/database/factories/ArticleFactory.php +++ b/database/factories/ArticleFactory.php @@ -6,6 +6,9 @@ use App\Models\Article; use Illuminate\Database\Eloquent\Factories\Factory; use Illuminate\Support\Carbon; +/** + * @extends \Illuminate\Database\Eloquent\Factories\Factory<\App\Models\Article> + */ class ArticleFactory extends Factory { /** @@ -18,9 +21,9 @@ class ArticleFactory extends Factory /** * Define the model's default state. * - * @return array + * @return array */ - public function definition() + public function definition(): array { return [ 'titleurl' => $this->faker->slug(3), diff --git a/database/factories/BookmarkFactory.php b/database/factories/BookmarkFactory.php index ae4e7848..ddfe0f97 100644 --- a/database/factories/BookmarkFactory.php +++ b/database/factories/BookmarkFactory.php @@ -6,6 +6,9 @@ use App\Models\Bookmark; use Illuminate\Database\Eloquent\Factories\Factory; use Illuminate\Support\Carbon; +/** + * @extends \Illuminate\Database\Eloquent\Factories\Factory<\App\Models\Bookmark> + */ class BookmarkFactory extends Factory { /** @@ -18,9 +21,9 @@ class BookmarkFactory extends Factory /** * Define the model's default state. * - * @return array + * @return array */ - public function definition() + public function definition(): array { $now = Carbon::now()->subDays(rand(5, 15)); diff --git a/database/factories/ContactFactory.php b/database/factories/ContactFactory.php index 175bc280..1b0be43b 100644 --- a/database/factories/ContactFactory.php +++ b/database/factories/ContactFactory.php @@ -6,6 +6,9 @@ use App\Models\Contact; use Illuminate\Database\Eloquent\Factories\Factory; use Illuminate\Support\Carbon; +/** + * @extends \Illuminate\Database\Eloquent\Factories\Factory<\App\Models\Contact> + */ class ContactFactory extends Factory { /** @@ -18,9 +21,9 @@ class ContactFactory extends Factory /** * Define the model's default state. * - * @return array + * @return array */ - public function definition() + public function definition(): array { return [ 'nick' => mb_strtolower($this->faker->firstName), diff --git a/database/factories/LikeFactory.php b/database/factories/LikeFactory.php index ed6510c1..8bf4f62f 100644 --- a/database/factories/LikeFactory.php +++ b/database/factories/LikeFactory.php @@ -6,6 +6,9 @@ use App\Models\Like; use Illuminate\Database\Eloquent\Factories\Factory; use Illuminate\Support\Carbon; +/** + * @extends \Illuminate\Database\Eloquent\Factories\Factory<\App\Models\Like> + */ class LikeFactory extends Factory { /** @@ -18,9 +21,9 @@ class LikeFactory extends Factory /** * Define the model's default state. * - * @return array + * @return array */ - public function definition() + public function definition(): array { $now = Carbon::now()->subDays(rand(5, 15)); diff --git a/database/factories/MediaFactory.php b/database/factories/MediaFactory.php index b3a44d78..ca253109 100644 --- a/database/factories/MediaFactory.php +++ b/database/factories/MediaFactory.php @@ -6,6 +6,9 @@ use App\Models\Media; use Illuminate\Database\Eloquent\Factories\Factory; use Illuminate\Support\Carbon; +/** + * @extends \Illuminate\Database\Eloquent\Factories\Factory<\App\Models\Media> + */ class MediaFactory extends Factory { /** @@ -18,9 +21,9 @@ class MediaFactory extends Factory /** * Define the model's default state. * - * @return array + * @return array */ - public function definition() + public function definition(): array { return [ 'path' => 'media/' . $this->faker->uuid . '.jpg', diff --git a/database/factories/MicropubClientFactory.php b/database/factories/MicropubClientFactory.php index 73b08917..4916f404 100644 --- a/database/factories/MicropubClientFactory.php +++ b/database/factories/MicropubClientFactory.php @@ -5,6 +5,9 @@ namespace Database\Factories; use App\Models\MicropubClient; use Illuminate\Database\Eloquent\Factories\Factory; +/** + * @extends \Illuminate\Database\Eloquent\Factories\Factory<\App\Models\MicropubClient> + */ class MicropubClientFactory extends Factory { /** @@ -17,9 +20,9 @@ class MicropubClientFactory extends Factory /** * Define the model's default state. * - * @return array + * @return array */ - public function definition() + public function definition(): array { return [ 'client_url' => $this->faker->url, diff --git a/database/factories/NoteFactory.php b/database/factories/NoteFactory.php index cbe2e09d..e2238a23 100644 --- a/database/factories/NoteFactory.php +++ b/database/factories/NoteFactory.php @@ -7,6 +7,9 @@ use Exception; use Illuminate\Database\Eloquent\Factories\Factory; use Illuminate\Support\Carbon; +/** + * @extends \Illuminate\Database\Eloquent\Factories\Factory<\App\Models\Note> + */ class NoteFactory extends Factory { /** @@ -19,11 +22,11 @@ class NoteFactory extends Factory /** * Define the model's default state. * - * @return array + * @return array * * @throws Exception */ - public function definition() + public function definition(): array { $now = Carbon::now()->subDays(random_int(5, 15)); diff --git a/database/factories/PlaceFactory.php b/database/factories/PlaceFactory.php index ef531e02..61bdd70f 100644 --- a/database/factories/PlaceFactory.php +++ b/database/factories/PlaceFactory.php @@ -5,6 +5,9 @@ namespace Database\Factories; use App\Models\Place; use Illuminate\Database\Eloquent\Factories\Factory; +/** + * @extends \Illuminate\Database\Eloquent\Factories\Factory<\App\Models\Place> + */ class PlaceFactory extends Factory { /** @@ -17,9 +20,9 @@ class PlaceFactory extends Factory /** * Define the model's default state. * - * @return array + * @return array */ - public function definition() + public function definition(): array { return [ 'name' => $this->faker->company, diff --git a/database/factories/SyndicationTargetFactory.php b/database/factories/SyndicationTargetFactory.php index c877c9d4..05243632 100644 --- a/database/factories/SyndicationTargetFactory.php +++ b/database/factories/SyndicationTargetFactory.php @@ -14,7 +14,7 @@ class SyndicationTargetFactory extends Factory * * @return array */ - public function definition() + public function definition(): array { return [ 'uid' => $this->faker->url, diff --git a/database/factories/TagFactory.php b/database/factories/TagFactory.php index be4d3afd..24cae028 100644 --- a/database/factories/TagFactory.php +++ b/database/factories/TagFactory.php @@ -5,6 +5,9 @@ namespace Database\Factories; use App\Models\Tag; use Illuminate\Database\Eloquent\Factories\Factory; +/** + * @extends \Illuminate\Database\Eloquent\Factories\Factory<\App\Models\Tag> + */ class TagFactory extends Factory { /** @@ -17,9 +20,9 @@ class TagFactory extends Factory /** * Define the model's default state. * - * @return array + * @return array */ - public function definition() + public function definition(): array { return [ 'tag' => $this->faker->word, diff --git a/database/factories/UserFactory.php b/database/factories/UserFactory.php index 7efccfd4..ba1ff997 100644 --- a/database/factories/UserFactory.php +++ b/database/factories/UserFactory.php @@ -6,6 +6,9 @@ use App\Models\User; use Illuminate\Database\Eloquent\Factories\Factory; use Illuminate\Support\Str; +/** + * @extends \Illuminate\Database\Eloquent\Factories\Factory<\App\Models\User> + */ class UserFactory extends Factory { /** @@ -18,9 +21,9 @@ class UserFactory extends Factory /** * Define the model's default state. * - * @return array + * @return array */ - public function definition() + public function definition(): array { return [ 'name' => $this->faker->name, diff --git a/database/factories/WebMentionFactory.php b/database/factories/WebMentionFactory.php index b9a97fef..65dbb92f 100644 --- a/database/factories/WebMentionFactory.php +++ b/database/factories/WebMentionFactory.php @@ -5,6 +5,9 @@ namespace Database\Factories; use App\Models\WebMention; use Illuminate\Database\Eloquent\Factories\Factory; +/** + * @extends \Illuminate\Database\Eloquent\Factories\Factory<\App\Models\WebMention> + */ class WebMentionFactory extends Factory { /** @@ -17,9 +20,9 @@ class WebMentionFactory extends Factory /** * Define the model's default state. * - * @return array + * @return array */ - public function definition() + public function definition(): array { return [ 'source' => $this->faker->url, diff --git a/database/migrations/2015_02_28_132629_create_articles_table.php b/database/migrations/2015_02_28_132629_create_articles_table.php deleted file mode 100644 index 5b2ec299..00000000 --- a/database/migrations/2015_02_28_132629_create_articles_table.php +++ /dev/null @@ -1,38 +0,0 @@ -increments('id'); - $table->string('titleurl', 50)->unique(); - $table->string('url', 120)->nullable(); - $table->string('title'); - $table->longText('main'); - $table->tinyInteger('published')->default(0); - $table->timestamps(); - $table->softDeletes(); - }); - } - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::drop('articles'); - } -} diff --git a/database/migrations/2015_02_28_144939_create_notes_table.php b/database/migrations/2015_02_28_144939_create_notes_table.php deleted file mode 100644 index 50196f81..00000000 --- a/database/migrations/2015_02_28_144939_create_notes_table.php +++ /dev/null @@ -1,40 +0,0 @@ -increments('id'); - $table->text('note'); - $table->string('in_reply_to')->nullable(); - $table->string('shorturl', 20)->nullable(); - $table->string('location')->nullable(); - $table->tinyInteger('photo')->nullable(); - $table->string('tweet_id')->nullable(); - $table->string('client_id')->nullable(); - $table->timestamps(); - $table->softDeletes(); - }); - } - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::drop('notes'); - } -} diff --git a/database/migrations/2015_03_02_084342_create_tags_table.php b/database/migrations/2015_03_02_084342_create_tags_table.php deleted file mode 100644 index 0e395f8c..00000000 --- a/database/migrations/2015_03_02_084342_create_tags_table.php +++ /dev/null @@ -1,31 +0,0 @@ -increments('id'); - $table->string('tag'); - $table->timestamps(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::drop('tags'); - } -} diff --git a/database/migrations/2015_03_02_084956_create_note_tag_table.php b/database/migrations/2015_03_02_084956_create_note_tag_table.php deleted file mode 100644 index 0c111ab0..00000000 --- a/database/migrations/2015_03_02_084956_create_note_tag_table.php +++ /dev/null @@ -1,33 +0,0 @@ -increments('id'); - $table->integer('note_id')->unsigned(); - $table->integer('tag_id')->unsigned(); - $table->foreign('note_id')->references('id')->on('notes'); - $table->foreign('tag_id')->references('id')->on('tags'); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::drop('note_tag'); - } -} diff --git a/database/migrations/2015_03_02_105623_create_contacts_table.php b/database/migrations/2015_03_02_105623_create_contacts_table.php deleted file mode 100644 index 8944d068..00000000 --- a/database/migrations/2015_03_02_105623_create_contacts_table.php +++ /dev/null @@ -1,34 +0,0 @@ -increments('id'); - $table->string('nick'); - $table->string('name'); - $table->string('homepage')->nullable(); - $table->string('twitter')->nullable(); - $table->timestamps(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::drop('contacts'); - } -} diff --git a/database/migrations/2015_03_02_114340_create_web_mentions_table.php b/database/migrations/2015_03_02_114340_create_web_mentions_table.php deleted file mode 100644 index aa29fe2e..00000000 --- a/database/migrations/2015_03_02_114340_create_web_mentions_table.php +++ /dev/null @@ -1,38 +0,0 @@ -increments('id'); - $table->string('source'); - $table->string('target'); - $table->integer('commentable_id')->nullable(); - $table->string('commentable_type')->nullable(); - $table->string('type')->nullable(); - $table->text('content')->nullable(); - $table->tinyInteger('verified')->default(1); - $table->timestamps(); - $table->softDeletes(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::drop('webmentions'); - } -} diff --git a/database/migrations/2015_07_17_111512_create_clients_table.php b/database/migrations/2015_07_17_111512_create_clients_table.php deleted file mode 100644 index b545c641..00000000 --- a/database/migrations/2015_07_17_111512_create_clients_table.php +++ /dev/null @@ -1,32 +0,0 @@ -increments('id'); - $table->string('client_url'); - $table->string('client_name'); - $table->timestamps(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::drop('clients'); - } -} diff --git a/database/migrations/2015_10_08_155111_create_media_table.php b/database/migrations/2015_10_08_155111_create_media_table.php deleted file mode 100644 index d30bceca..00000000 --- a/database/migrations/2015_10_08_155111_create_media_table.php +++ /dev/null @@ -1,36 +0,0 @@ -increments('id'); - $table->morphs('model'); - $table->string('collection_name'); - $table->string('name'); - $table->string('file_name'); - $table->string('disk'); - $table->unsignedInteger('size'); - $table->text('manipulations'); - $table->text('custom_properties'); - $table->unsignedInteger('order_column')->nullable(); - $table->timestamps(); - }); - } - - /** - * Reverse the migrations. - */ - public function down() - { - Schema::drop('media'); - } -} diff --git a/database/migrations/2015_11_07_130637_create_places_table.php b/database/migrations/2015_11_07_130637_create_places_table.php deleted file mode 100644 index 8630b95f..00000000 --- a/database/migrations/2015_11_07_130637_create_places_table.php +++ /dev/null @@ -1,35 +0,0 @@ -increments('id'); - $table->string('name'); - $table->string('slug')->unique(); - $table->text('description')->nullable(); - $table->text('location'); - $table->text('polygon')->nullable(); - $table->timestamps(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::drop('places'); - } -} diff --git a/database/migrations/2015_11_19_221933_add_place_relation_to_notes.php b/database/migrations/2015_11_19_221933_add_place_relation_to_notes.php deleted file mode 100644 index 762b6830..00000000 --- a/database/migrations/2015_11_19_221933_add_place_relation_to_notes.php +++ /dev/null @@ -1,33 +0,0 @@ -integer('place_id')->unsigned()->nullable(); - $table->foreign('place_id')->references('id')->on('places'); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::table('notes', function (Blueprint $table) { - $table->dropForeign('notes_place_id_foreign'); - $table->dropColumn('place_id'); - }); - } -} diff --git a/database/migrations/2016_07_29_113150_add_jsonb_mf2_column_to_webmentions_table.php b/database/migrations/2016_07_29_113150_add_jsonb_mf2_column_to_webmentions_table.php deleted file mode 100644 index 131273df..00000000 --- a/database/migrations/2016_07_29_113150_add_jsonb_mf2_column_to_webmentions_table.php +++ /dev/null @@ -1,33 +0,0 @@ -jsonb('mf2')->nullable(); - $table->index(['mf2']); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::table('webmentions', function (Blueprint $table) { - $table->dropIndex(['mf2']); - $table->dropColumn('mf2'); - }); - } -} diff --git a/database/migrations/2016_09_30_214651_cascade_delete_note_tags.php b/database/migrations/2016_09_30_214651_cascade_delete_note_tags.php deleted file mode 100644 index 6381f27c..00000000 --- a/database/migrations/2016_09_30_214651_cascade_delete_note_tags.php +++ /dev/null @@ -1,30 +0,0 @@ -dropForeign('note_tag_note_id_foreign'); - $table->foreign('note_id')->references('id')->on('notes')->onDelete('cascade'); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - // - } -} diff --git a/database/migrations/2016_10_26_170858_add_facebook_url_column_to_notes.php b/database/migrations/2016_10_26_170858_add_facebook_url_column_to_notes.php deleted file mode 100644 index ed5dd250..00000000 --- a/database/migrations/2016_10_26_170858_add_facebook_url_column_to_notes.php +++ /dev/null @@ -1,30 +0,0 @@ -string('facebook_url')->nullable(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - // - } -} diff --git a/database/migrations/2016_11_23_154939_add_facebook_to_contacts.php b/database/migrations/2016_11_23_154939_add_facebook_to_contacts.php deleted file mode 100644 index b5c7fd1c..00000000 --- a/database/migrations/2016_11_23_154939_add_facebook_to_contacts.php +++ /dev/null @@ -1,32 +0,0 @@ -string('facebook')->nullable(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::table('contacts', function (Blueprint $table) { - $table->dropColumn('facebook'); - }); - } -} diff --git a/database/migrations/2016_12_05_204035_add_search_to_notes.php b/database/migrations/2016_12_05_204035_add_search_to_notes.php deleted file mode 100644 index fa7a6493..00000000 --- a/database/migrations/2016_12_05_204035_add_search_to_notes.php +++ /dev/null @@ -1,33 +0,0 @@ -string('icon')->nullable(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::table('places', function (Blueprint $table) { - $table->dropColumn('icon'); - }); - } -} diff --git a/database/migrations/2017_03_09_155908_create_media_endpoint_table.php b/database/migrations/2017_03_09_155908_create_media_endpoint_table.php deleted file mode 100644 index cd48f961..00000000 --- a/database/migrations/2017_03_09_155908_create_media_endpoint_table.php +++ /dev/null @@ -1,41 +0,0 @@ -increments('id'); - $table->text('token')->nullable(); - $table->string('path'); - $table->string('type'); - $table->unsignedInteger('note_id')->nullable(); - $table->timestamps(); - - $table->index('token'); - $table->foreign('note_id')->references('id')->on('notes'); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::table('media_endpoint', function (Blueprint $table) { - $table->dropForeign(['note_id']); - }); - Schema::dropIfExists('media_endpoint'); - } -} diff --git a/database/migrations/2017_03_28_130855_create_indie_web_users_table.php b/database/migrations/2017_03_28_130855_create_indie_web_users_table.php deleted file mode 100644 index 53b9ea8f..00000000 --- a/database/migrations/2017_03_28_130855_create_indie_web_users_table.php +++ /dev/null @@ -1,36 +0,0 @@ -increments('id'); - $table->string('me')->unique(); - $table->text('token')->nullable(); - $table->string('syntax')->default('json'); - $table->jsonb('syndication')->nullable(); - $table->string('mediaEndpoint')->nullable(); - $table->timestamps(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::dropIfExists('indie_web_users'); - } -} diff --git a/database/migrations/2017_04_25_203734_update_notes_table_add_swarm_url.php b/database/migrations/2017_04_25_203734_update_notes_table_add_swarm_url.php deleted file mode 100644 index b5f72a18..00000000 --- a/database/migrations/2017_04_25_203734_update_notes_table_add_swarm_url.php +++ /dev/null @@ -1,32 +0,0 @@ -string('swarm_url')->nullable(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::table('notes', function (Blueprint $table) { - $table->dropColumn('swarm_url'); - }); - } -} diff --git a/database/migrations/2017_05_12_135451_update_places_table_add_foursquare_column.php b/database/migrations/2017_05_12_135451_update_places_table_add_foursquare_column.php deleted file mode 100644 index f4b16629..00000000 --- a/database/migrations/2017_05_12_135451_update_places_table_add_foursquare_column.php +++ /dev/null @@ -1,32 +0,0 @@ -string('foursquare')->nullable(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::table('places', function (Blueprint $table) { - $table->dropColumn('foursquare'); - }); - } -} diff --git a/database/migrations/2017_06_11_193737_update_notes_table_add_instagram_url.php b/database/migrations/2017_06_11_193737_update_notes_table_add_instagram_url.php deleted file mode 100644 index 1eb120e8..00000000 --- a/database/migrations/2017_06_11_193737_update_notes_table_add_instagram_url.php +++ /dev/null @@ -1,32 +0,0 @@ -string('instagram_url')->nullable(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::table('notes', function (Blueprint $table) { - $table->dropColumn('instagram_url'); - }); - } -} diff --git a/database/migrations/2017_06_27_164743_update_places_table_add_external_urls.php b/database/migrations/2017_06_27_164743_update_places_table_add_external_urls.php deleted file mode 100644 index e4acfe8f..00000000 --- a/database/migrations/2017_06_27_164743_update_places_table_add_external_urls.php +++ /dev/null @@ -1,34 +0,0 @@ -jsonb('external_urls')->nullable(); - $table->index('external_urls'); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::table('places', function (Blueprint $table) { - $table->dropIndex('places_external_urls_index'); - $table->dropColumn('external_urls'); - }); - } -} diff --git a/database/migrations/2017_08_09_181357_allow_empty_note_content.php b/database/migrations/2017_08_09_181357_allow_empty_note_content.php deleted file mode 100644 index dbe415fe..00000000 --- a/database/migrations/2017_08_09_181357_allow_empty_note_content.php +++ /dev/null @@ -1,34 +0,0 @@ -text('image_widths')->nullable(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::table('media_endpoint', function (Blueprint $table) { - $table->dropColumn('image_widths'); - }); - } -} diff --git a/database/migrations/2017_09_16_191741_create_likes_table.php b/database/migrations/2017_09_16_191741_create_likes_table.php deleted file mode 100644 index 5435d9e1..00000000 --- a/database/migrations/2017_09_16_191741_create_likes_table.php +++ /dev/null @@ -1,35 +0,0 @@ -increments('id'); - $table->string('url'); - $table->string('author_name')->nullable(); - $table->string('author_url')->nullable(); - $table->text('content')->nullable(); - $table->timestamps(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::dropIfExists('likes'); - } -} diff --git a/database/migrations/2017_10_07_163425_create_bookmarks_table.php b/database/migrations/2017_10_07_163425_create_bookmarks_table.php deleted file mode 100644 index 8bcaeadf..00000000 --- a/database/migrations/2017_10_07_163425_create_bookmarks_table.php +++ /dev/null @@ -1,37 +0,0 @@ -increments('id'); - $table->string('url'); - $table->string('name')->nullable(); - $table->text('content')->nullable(); - $table->uuid('screenshot')->nullable(); - $table->string('archive')->nullable(); - $table->jsonb('syndicates')->nullable(); - $table->timestamps(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::dropIfExists('bookmarks'); - } -} diff --git a/database/migrations/2017_10_07_164651_create_bookmark_tag_pivot_table.php b/database/migrations/2017_10_07_164651_create_bookmark_tag_pivot_table.php deleted file mode 100644 index e3d13929..00000000 --- a/database/migrations/2017_10_07_164651_create_bookmark_tag_pivot_table.php +++ /dev/null @@ -1,36 +0,0 @@ -increments('id'); - $table->unsignedInteger('bookmark_id'); - $table->unsignedInteger('tag_id'); - $table->timestamps(); - - $table->foreign('bookmark_id')->references('id')->on('bookmarks'); - $table->foreign('tag_id')->references('id')->on('tags'); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::dropIfExists('bookmark_tag'); - } -} diff --git a/database/migrations/2017_12_19_160117_update_models_reference_in_webmentions_table.php b/database/migrations/2017_12_19_160117_update_models_reference_in_webmentions_table.php deleted file mode 100644 index 0cec1b4c..00000000 --- a/database/migrations/2017_12_19_160117_update_models_reference_in_webmentions_table.php +++ /dev/null @@ -1,32 +0,0 @@ -schema = Schema::connection( - config('telescope.storage.database.connection') - ); - } - - /** - * Run the migrations. - * - * @return void - */ - public function up() - { - $this->schema->create('telescope_entries', function (Blueprint $table) { - $table->bigIncrements('sequence'); - $table->uuid('uuid'); - $table->uuid('batch_id'); - $table->string('family_hash')->nullable()->index(); - $table->boolean('should_display_on_index')->default(true); - $table->string('type', 20); - $table->longText('content'); - $table->dateTime('created_at')->nullable(); - - $table->unique('uuid'); - $table->index('batch_id'); - $table->index(['type', 'should_display_on_index']); - }); - - $this->schema->create('telescope_entries_tags', function (Blueprint $table) { - $table->uuid('entry_uuid'); - $table->string('tag'); - - $table->index(['entry_uuid', 'tag']); - $table->index('tag'); - - $table->foreign('entry_uuid') - ->references('uuid') - ->on('telescope_entries') - ->onDelete('cascade'); - }); - - $this->schema->create('telescope_monitoring', function (Blueprint $table) { - $table->string('tag'); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - $this->schema->dropIfExists('telescope_entries_tags'); - $this->schema->dropIfExists('telescope_entries'); - $this->schema->dropIfExists('telescope_monitoring'); - } -} diff --git a/database/migrations/2019_03_20_181657_create_users_table.php b/database/migrations/2019_03_20_181657_create_users_table.php deleted file mode 100644 index 1194e768..00000000 --- a/database/migrations/2019_03_20_181657_create_users_table.php +++ /dev/null @@ -1,34 +0,0 @@ -bigIncrements('id'); - $table->string('name'); - $table->string('password'); - $table->rememberToken(); - $table->timestamps(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::dropIfExists('users'); - } -} diff --git a/database/migrations/2020_10_10_191546_add_latitude-longitude_columns.php b/database/migrations/2020_10_10_191546_add_latitude-longitude_columns.php deleted file mode 100644 index fc3e01cb..00000000 --- a/database/migrations/2020_10_10_191546_add_latitude-longitude_columns.php +++ /dev/null @@ -1,34 +0,0 @@ -float('latitude')->nullable(); - $table->float('longitude')->nullable(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::table('places', function (Blueprint $table) { - $table->dropColumn('latitude'); - $table->dropColumn('longitude'); - }); - } -} diff --git a/database/migrations/2020_10_16_153324_remove_location_column.php b/database/migrations/2020_10_16_153324_remove_location_column.php deleted file mode 100644 index fdeb7b03..00000000 --- a/database/migrations/2020_10_16_153324_remove_location_column.php +++ /dev/null @@ -1,21 +0,0 @@ -dropColumn('location'); - $table->dropColumn('polygon'); - }); - } -} diff --git a/database/migrations/2022_02_27_182404_remove_notes_searchable_tsvector.php b/database/migrations/2022_02_27_182404_remove_notes_searchable_tsvector.php deleted file mode 100644 index c152a5d1..00000000 --- a/database/migrations/2022_02_27_182404_remove_notes_searchable_tsvector.php +++ /dev/null @@ -1,34 +0,0 @@ -id(); - $table->string('uid'); - $table->string('name'); - $table->string('service_name')->nullable(); - $table->string('service_url')->nullable(); - $table->string('service_photo')->nullable(); - $table->string('user_name')->nullable(); - $table->string('user_url')->nullable(); - $table->string('user_photo')->nullable(); - $table->timestamps(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::dropIfExists('syndication_targets'); - } -}; diff --git a/database/migrations/2022_10_26_180903_add_mastodon_syndication_url.php b/database/migrations/2022_10_26_180903_add_mastodon_syndication_url.php deleted file mode 100644 index 48c4403e..00000000 --- a/database/migrations/2022_10_26_180903_add_mastodon_syndication_url.php +++ /dev/null @@ -1,32 +0,0 @@ -string('mastodon_url')->nullable(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::table('notes', function (Blueprint $table) { - $table->dropColumn('mastodon_url'); - }); - } -}; diff --git a/database/migrations/2022_11_21_184127_remove_old_failed_jobs_table.php b/database/migrations/2022_11_21_184127_remove_old_failed_jobs_table.php deleted file mode 100644 index 9c2cc1d8..00000000 --- a/database/migrations/2022_11_21_184127_remove_old_failed_jobs_table.php +++ /dev/null @@ -1,27 +0,0 @@ -id(); - $table->string('uuid')->unique(); - $table->text('connection'); - $table->text('queue'); - $table->longText('payload'); - $table->longText('exception'); - $table->timestamp('failed_at')->useCurrent(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::dropIfExists('failed_jobs'); - } -}; diff --git a/database/schema/pgsql-schema.sql b/database/schema/pgsql-schema.sql new file mode 100644 index 00000000..6dae72e5 --- /dev/null +++ b/database/schema/pgsql-schema.sql @@ -0,0 +1,1312 @@ +-- +-- PostgreSQL database dump +-- + +-- Dumped from database version 14.4 (Debian 14.4-1.pgdg110+1) +-- Dumped by pg_dump version 14.6 (Ubuntu 14.6-1.pgdg22.04+1) + +SET statement_timeout = 0; +SET lock_timeout = 0; +SET idle_in_transaction_session_timeout = 0; +SET client_encoding = 'UTF8'; +SET standard_conforming_strings = on; +SELECT pg_catalog.set_config('search_path', '', false); +SET check_function_bodies = false; +SET xmloption = content; +SET client_min_messages = warning; +SET row_security = off; + +SET default_tablespace = ''; + +SET default_table_access_method = heap; + +-- +-- Name: articles; Type: TABLE; Schema: public; Owner: - +-- + +CREATE TABLE public.articles ( + id integer NOT NULL, + titleurl character varying(50) NOT NULL, + url character varying(120), + title character varying(255) NOT NULL, + main text NOT NULL, + published smallint DEFAULT '0'::smallint NOT NULL, + created_at timestamp(0) without time zone, + updated_at timestamp(0) without time zone, + deleted_at timestamp(0) without time zone +); + + +-- +-- Name: articles_id_seq; Type: SEQUENCE; Schema: public; Owner: - +-- + +CREATE SEQUENCE public.articles_id_seq + AS integer + START WITH 1 + INCREMENT BY 1 + NO MINVALUE + NO MAXVALUE + CACHE 1; + + +-- +-- Name: articles_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - +-- + +ALTER SEQUENCE public.articles_id_seq OWNED BY public.articles.id; + + +-- +-- Name: bookmark_tag; Type: TABLE; Schema: public; Owner: - +-- + +CREATE TABLE public.bookmark_tag ( + id integer NOT NULL, + bookmark_id integer NOT NULL, + tag_id integer NOT NULL, + created_at timestamp(0) without time zone, + updated_at timestamp(0) without time zone +); + + +-- +-- Name: bookmark_tag_id_seq; Type: SEQUENCE; Schema: public; Owner: - +-- + +CREATE SEQUENCE public.bookmark_tag_id_seq + AS integer + START WITH 1 + INCREMENT BY 1 + NO MINVALUE + NO MAXVALUE + CACHE 1; + + +-- +-- Name: bookmark_tag_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - +-- + +ALTER SEQUENCE public.bookmark_tag_id_seq OWNED BY public.bookmark_tag.id; + + +-- +-- Name: bookmarks; Type: TABLE; Schema: public; Owner: - +-- + +CREATE TABLE public.bookmarks ( + id integer NOT NULL, + url character varying(255) NOT NULL, + name character varying(255), + content text, + screenshot uuid, + archive character varying(255), + syndicates jsonb, + created_at timestamp(0) without time zone, + updated_at timestamp(0) without time zone +); + + +-- +-- Name: bookmarks_id_seq; Type: SEQUENCE; Schema: public; Owner: - +-- + +CREATE SEQUENCE public.bookmarks_id_seq + AS integer + START WITH 1 + INCREMENT BY 1 + NO MINVALUE + NO MAXVALUE + CACHE 1; + + +-- +-- Name: bookmarks_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - +-- + +ALTER SEQUENCE public.bookmarks_id_seq OWNED BY public.bookmarks.id; + + +-- +-- Name: clients; Type: TABLE; Schema: public; Owner: - +-- + +CREATE TABLE public.clients ( + id integer NOT NULL, + client_url character varying(255) NOT NULL, + client_name character varying(255) NOT NULL, + created_at timestamp(0) without time zone, + updated_at timestamp(0) without time zone +); + + +-- +-- Name: clients_id_seq; Type: SEQUENCE; Schema: public; Owner: - +-- + +CREATE SEQUENCE public.clients_id_seq + AS integer + START WITH 1 + INCREMENT BY 1 + NO MINVALUE + NO MAXVALUE + CACHE 1; + + +-- +-- Name: clients_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - +-- + +ALTER SEQUENCE public.clients_id_seq OWNED BY public.clients.id; + + +-- +-- Name: contacts; Type: TABLE; Schema: public; Owner: - +-- + +CREATE TABLE public.contacts ( + id integer NOT NULL, + nick character varying(255) NOT NULL, + name character varying(255) NOT NULL, + homepage character varying(255), + twitter character varying(255), + created_at timestamp(0) without time zone, + updated_at timestamp(0) without time zone, + facebook character varying(255) +); + + +-- +-- Name: contacts_id_seq; Type: SEQUENCE; Schema: public; Owner: - +-- + +CREATE SEQUENCE public.contacts_id_seq + AS integer + START WITH 1 + INCREMENT BY 1 + NO MINVALUE + NO MAXVALUE + CACHE 1; + + +-- +-- Name: contacts_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - +-- + +ALTER SEQUENCE public.contacts_id_seq OWNED BY public.contacts.id; + + +-- +-- Name: failed_jobs; Type: TABLE; Schema: public; Owner: - +-- + +CREATE TABLE public.failed_jobs ( + id bigint NOT NULL, + uuid character varying(255) NOT NULL, + connection text NOT NULL, + queue text NOT NULL, + payload text NOT NULL, + exception text NOT NULL, + failed_at timestamp(0) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL +); + + +-- +-- Name: failed_jobs_id_seq; Type: SEQUENCE; Schema: public; Owner: - +-- + +CREATE SEQUENCE public.failed_jobs_id_seq + START WITH 1 + INCREMENT BY 1 + NO MINVALUE + NO MAXVALUE + CACHE 1; + + +-- +-- Name: failed_jobs_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - +-- + +ALTER SEQUENCE public.failed_jobs_id_seq OWNED BY public.failed_jobs.id; + + +-- +-- Name: indie_web_users; Type: TABLE; Schema: public; Owner: - +-- + +CREATE TABLE public.indie_web_users ( + id integer NOT NULL, + me character varying(255) NOT NULL, + token text, + syntax character varying(255) DEFAULT 'json'::character varying NOT NULL, + syndication jsonb, + "mediaEndpoint" character varying(255), + created_at timestamp(0) without time zone, + updated_at timestamp(0) without time zone +); + + +-- +-- Name: indie_web_users_id_seq; Type: SEQUENCE; Schema: public; Owner: - +-- + +CREATE SEQUENCE public.indie_web_users_id_seq + AS integer + START WITH 1 + INCREMENT BY 1 + NO MINVALUE + NO MAXVALUE + CACHE 1; + + +-- +-- Name: indie_web_users_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - +-- + +ALTER SEQUENCE public.indie_web_users_id_seq OWNED BY public.indie_web_users.id; + + +-- +-- Name: likes; Type: TABLE; Schema: public; Owner: - +-- + +CREATE TABLE public.likes ( + id integer NOT NULL, + url character varying(255) NOT NULL, + author_name character varying(255), + author_url character varying(255), + content text, + created_at timestamp(0) without time zone, + updated_at timestamp(0) without time zone +); + + +-- +-- Name: likes_id_seq; Type: SEQUENCE; Schema: public; Owner: - +-- + +CREATE SEQUENCE public.likes_id_seq + AS integer + START WITH 1 + INCREMENT BY 1 + NO MINVALUE + NO MAXVALUE + CACHE 1; + + +-- +-- Name: likes_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - +-- + +ALTER SEQUENCE public.likes_id_seq OWNED BY public.likes.id; + + +-- +-- Name: media; Type: TABLE; Schema: public; Owner: - +-- + +CREATE TABLE public.media ( + id integer NOT NULL, + model_type character varying(255) NOT NULL, + model_id bigint NOT NULL, + collection_name character varying(255) NOT NULL, + name character varying(255) NOT NULL, + file_name character varying(255) NOT NULL, + disk character varying(255) NOT NULL, + size integer NOT NULL, + manipulations text NOT NULL, + custom_properties text NOT NULL, + order_column integer, + created_at timestamp(0) without time zone, + updated_at timestamp(0) without time zone +); + + +-- +-- Name: media_endpoint; Type: TABLE; Schema: public; Owner: - +-- + +CREATE TABLE public.media_endpoint ( + id integer NOT NULL, + token text, + path character varying(255) NOT NULL, + type character varying(255) NOT NULL, + note_id integer, + created_at timestamp(0) without time zone, + updated_at timestamp(0) without time zone, + image_widths text +); + + +-- +-- Name: media_endpoint_id_seq; Type: SEQUENCE; Schema: public; Owner: - +-- + +CREATE SEQUENCE public.media_endpoint_id_seq + AS integer + START WITH 1 + INCREMENT BY 1 + NO MINVALUE + NO MAXVALUE + CACHE 1; + + +-- +-- Name: media_endpoint_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - +-- + +ALTER SEQUENCE public.media_endpoint_id_seq OWNED BY public.media_endpoint.id; + + +-- +-- Name: media_id_seq; Type: SEQUENCE; Schema: public; Owner: - +-- + +CREATE SEQUENCE public.media_id_seq + AS integer + START WITH 1 + INCREMENT BY 1 + NO MINVALUE + NO MAXVALUE + CACHE 1; + + +-- +-- Name: media_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - +-- + +ALTER SEQUENCE public.media_id_seq OWNED BY public.media.id; + + +-- +-- Name: migrations; Type: TABLE; Schema: public; Owner: - +-- + +CREATE TABLE public.migrations ( + id integer NOT NULL, + migration character varying(255) NOT NULL, + batch integer NOT NULL +); + + +-- +-- Name: migrations_id_seq; Type: SEQUENCE; Schema: public; Owner: - +-- + +CREATE SEQUENCE public.migrations_id_seq + AS integer + START WITH 1 + INCREMENT BY 1 + NO MINVALUE + NO MAXVALUE + CACHE 1; + + +-- +-- Name: migrations_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - +-- + +ALTER SEQUENCE public.migrations_id_seq OWNED BY public.migrations.id; + + +-- +-- Name: note_tag; Type: TABLE; Schema: public; Owner: - +-- + +CREATE TABLE public.note_tag ( + id integer NOT NULL, + note_id integer NOT NULL, + tag_id integer NOT NULL +); + + +-- +-- Name: note_tag_id_seq; Type: SEQUENCE; Schema: public; Owner: - +-- + +CREATE SEQUENCE public.note_tag_id_seq + AS integer + START WITH 1 + INCREMENT BY 1 + NO MINVALUE + NO MAXVALUE + CACHE 1; + + +-- +-- Name: note_tag_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - +-- + +ALTER SEQUENCE public.note_tag_id_seq OWNED BY public.note_tag.id; + + +-- +-- Name: notes; Type: TABLE; Schema: public; Owner: - +-- + +CREATE TABLE public.notes ( + id integer NOT NULL, + note text, + in_reply_to character varying(255), + shorturl character varying(20), + location character varying(255), + photo smallint, + tweet_id character varying(255), + client_id character varying(255), + created_at timestamp(0) without time zone, + updated_at timestamp(0) without time zone, + deleted_at timestamp(0) without time zone, + place_id integer, + facebook_url character varying(255), + swarm_url character varying(255), + instagram_url character varying(255), + mastodon_url character varying(255) +); + + +-- +-- Name: notes_id_seq; Type: SEQUENCE; Schema: public; Owner: - +-- + +CREATE SEQUENCE public.notes_id_seq + AS integer + START WITH 1 + INCREMENT BY 1 + NO MINVALUE + NO MAXVALUE + CACHE 1; + + +-- +-- Name: notes_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - +-- + +ALTER SEQUENCE public.notes_id_seq OWNED BY public.notes.id; + + +-- +-- Name: personal_access_tokens; Type: TABLE; Schema: public; Owner: - +-- + +CREATE TABLE public.personal_access_tokens ( + id bigint NOT NULL, + tokenable_type character varying(255) NOT NULL, + tokenable_id bigint NOT NULL, + name character varying(255) NOT NULL, + token character varying(64) NOT NULL, + abilities text, + last_used_at timestamp(0) without time zone, + expires_at timestamp(0) without time zone, + created_at timestamp(0) without time zone, + updated_at timestamp(0) without time zone +); + + +-- +-- Name: personal_access_tokens_id_seq; Type: SEQUENCE; Schema: public; Owner: - +-- + +CREATE SEQUENCE public.personal_access_tokens_id_seq + START WITH 1 + INCREMENT BY 1 + NO MINVALUE + NO MAXVALUE + CACHE 1; + + +-- +-- Name: personal_access_tokens_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - +-- + +ALTER SEQUENCE public.personal_access_tokens_id_seq OWNED BY public.personal_access_tokens.id; + + +-- +-- Name: places; Type: TABLE; Schema: public; Owner: - +-- + +CREATE TABLE public.places ( + id integer NOT NULL, + name character varying(255) NOT NULL, + slug character varying(255) NOT NULL, + description text, + created_at timestamp(0) without time zone, + updated_at timestamp(0) without time zone, + icon character varying(255), + foursquare character varying(255), + external_urls jsonb, + latitude double precision, + longitude double precision +); + + +-- +-- Name: places_id_seq; Type: SEQUENCE; Schema: public; Owner: - +-- + +CREATE SEQUENCE public.places_id_seq + AS integer + START WITH 1 + INCREMENT BY 1 + NO MINVALUE + NO MAXVALUE + CACHE 1; + + +-- +-- Name: places_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - +-- + +ALTER SEQUENCE public.places_id_seq OWNED BY public.places.id; + + +-- +-- Name: syndication_targets; Type: TABLE; Schema: public; Owner: - +-- + +CREATE TABLE public.syndication_targets ( + id bigint NOT NULL, + uid character varying(255) NOT NULL, + name character varying(255) NOT NULL, + service_name character varying(255), + service_url character varying(255), + service_photo character varying(255), + user_name character varying(255), + user_url character varying(255), + user_photo character varying(255), + created_at timestamp(0) without time zone, + updated_at timestamp(0) without time zone +); + + +-- +-- Name: syndication_targets_id_seq; Type: SEQUENCE; Schema: public; Owner: - +-- + +CREATE SEQUENCE public.syndication_targets_id_seq + START WITH 1 + INCREMENT BY 1 + NO MINVALUE + NO MAXVALUE + CACHE 1; + + +-- +-- Name: syndication_targets_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - +-- + +ALTER SEQUENCE public.syndication_targets_id_seq OWNED BY public.syndication_targets.id; + + +-- +-- Name: tags; Type: TABLE; Schema: public; Owner: - +-- + +CREATE TABLE public.tags ( + id integer NOT NULL, + tag character varying(255) NOT NULL, + created_at timestamp(0) without time zone, + updated_at timestamp(0) without time zone +); + + +-- +-- Name: tags_id_seq; Type: SEQUENCE; Schema: public; Owner: - +-- + +CREATE SEQUENCE public.tags_id_seq + AS integer + START WITH 1 + INCREMENT BY 1 + NO MINVALUE + NO MAXVALUE + CACHE 1; + + +-- +-- Name: tags_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - +-- + +ALTER SEQUENCE public.tags_id_seq OWNED BY public.tags.id; + + +-- +-- Name: telescope_entries; Type: TABLE; Schema: public; Owner: - +-- + +CREATE TABLE public.telescope_entries ( + sequence bigint NOT NULL, + uuid uuid NOT NULL, + batch_id uuid NOT NULL, + family_hash character varying(255), + should_display_on_index boolean DEFAULT true NOT NULL, + type character varying(20) NOT NULL, + content text NOT NULL, + created_at timestamp(0) without time zone +); + + +-- +-- Name: telescope_entries_sequence_seq; Type: SEQUENCE; Schema: public; Owner: - +-- + +CREATE SEQUENCE public.telescope_entries_sequence_seq + START WITH 1 + INCREMENT BY 1 + NO MINVALUE + NO MAXVALUE + CACHE 1; + + +-- +-- Name: telescope_entries_sequence_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - +-- + +ALTER SEQUENCE public.telescope_entries_sequence_seq OWNED BY public.telescope_entries.sequence; + + +-- +-- Name: telescope_entries_tags; Type: TABLE; Schema: public; Owner: - +-- + +CREATE TABLE public.telescope_entries_tags ( + entry_uuid uuid NOT NULL, + tag character varying(255) NOT NULL +); + + +-- +-- Name: telescope_monitoring; Type: TABLE; Schema: public; Owner: - +-- + +CREATE TABLE public.telescope_monitoring ( + tag character varying(255) NOT NULL +); + + +-- +-- Name: users; Type: TABLE; Schema: public; Owner: - +-- + +CREATE TABLE public.users ( + id bigint NOT NULL, + name character varying(255) NOT NULL, + password character varying(255) NOT NULL, + remember_token character varying(100), + created_at timestamp(0) without time zone, + updated_at timestamp(0) without time zone +); + + +-- +-- Name: users_id_seq; Type: SEQUENCE; Schema: public; Owner: - +-- + +CREATE SEQUENCE public.users_id_seq + START WITH 1 + INCREMENT BY 1 + NO MINVALUE + NO MAXVALUE + CACHE 1; + + +-- +-- Name: users_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - +-- + +ALTER SEQUENCE public.users_id_seq OWNED BY public.users.id; + + +-- +-- Name: webmentions; Type: TABLE; Schema: public; Owner: - +-- + +CREATE TABLE public.webmentions ( + id integer NOT NULL, + source character varying(255) NOT NULL, + target character varying(255) NOT NULL, + commentable_id integer, + commentable_type character varying(255), + type character varying(255), + content text, + verified smallint DEFAULT '1'::smallint NOT NULL, + created_at timestamp(0) without time zone, + updated_at timestamp(0) without time zone, + deleted_at timestamp(0) without time zone, + mf2 jsonb +); + + +-- +-- Name: webmentions_id_seq; Type: SEQUENCE; Schema: public; Owner: - +-- + +CREATE SEQUENCE public.webmentions_id_seq + AS integer + START WITH 1 + INCREMENT BY 1 + NO MINVALUE + NO MAXVALUE + CACHE 1; + + +-- +-- Name: webmentions_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - +-- + +ALTER SEQUENCE public.webmentions_id_seq OWNED BY public.webmentions.id; + + +-- +-- Name: articles id; Type: DEFAULT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.articles ALTER COLUMN id SET DEFAULT nextval('public.articles_id_seq'::regclass); + + +-- +-- Name: bookmark_tag id; Type: DEFAULT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.bookmark_tag ALTER COLUMN id SET DEFAULT nextval('public.bookmark_tag_id_seq'::regclass); + + +-- +-- Name: bookmarks id; Type: DEFAULT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.bookmarks ALTER COLUMN id SET DEFAULT nextval('public.bookmarks_id_seq'::regclass); + + +-- +-- Name: clients id; Type: DEFAULT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.clients ALTER COLUMN id SET DEFAULT nextval('public.clients_id_seq'::regclass); + + +-- +-- Name: contacts id; Type: DEFAULT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.contacts ALTER COLUMN id SET DEFAULT nextval('public.contacts_id_seq'::regclass); + + +-- +-- Name: failed_jobs id; Type: DEFAULT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.failed_jobs ALTER COLUMN id SET DEFAULT nextval('public.failed_jobs_id_seq'::regclass); + + +-- +-- Name: indie_web_users id; Type: DEFAULT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.indie_web_users ALTER COLUMN id SET DEFAULT nextval('public.indie_web_users_id_seq'::regclass); + + +-- +-- Name: likes id; Type: DEFAULT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.likes ALTER COLUMN id SET DEFAULT nextval('public.likes_id_seq'::regclass); + + +-- +-- Name: media id; Type: DEFAULT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.media ALTER COLUMN id SET DEFAULT nextval('public.media_id_seq'::regclass); + + +-- +-- Name: media_endpoint id; Type: DEFAULT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.media_endpoint ALTER COLUMN id SET DEFAULT nextval('public.media_endpoint_id_seq'::regclass); + + +-- +-- Name: migrations id; Type: DEFAULT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.migrations ALTER COLUMN id SET DEFAULT nextval('public.migrations_id_seq'::regclass); + + +-- +-- Name: note_tag id; Type: DEFAULT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.note_tag ALTER COLUMN id SET DEFAULT nextval('public.note_tag_id_seq'::regclass); + + +-- +-- Name: notes id; Type: DEFAULT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.notes ALTER COLUMN id SET DEFAULT nextval('public.notes_id_seq'::regclass); + + +-- +-- Name: personal_access_tokens id; Type: DEFAULT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.personal_access_tokens ALTER COLUMN id SET DEFAULT nextval('public.personal_access_tokens_id_seq'::regclass); + + +-- +-- Name: places id; Type: DEFAULT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.places ALTER COLUMN id SET DEFAULT nextval('public.places_id_seq'::regclass); + + +-- +-- Name: syndication_targets id; Type: DEFAULT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.syndication_targets ALTER COLUMN id SET DEFAULT nextval('public.syndication_targets_id_seq'::regclass); + + +-- +-- Name: tags id; Type: DEFAULT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.tags ALTER COLUMN id SET DEFAULT nextval('public.tags_id_seq'::regclass); + + +-- +-- Name: telescope_entries sequence; Type: DEFAULT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.telescope_entries ALTER COLUMN sequence SET DEFAULT nextval('public.telescope_entries_sequence_seq'::regclass); + + +-- +-- Name: users id; Type: DEFAULT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.users ALTER COLUMN id SET DEFAULT nextval('public.users_id_seq'::regclass); + + +-- +-- Name: webmentions id; Type: DEFAULT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.webmentions ALTER COLUMN id SET DEFAULT nextval('public.webmentions_id_seq'::regclass); + + +-- +-- Name: articles articles_pkey; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.articles + ADD CONSTRAINT articles_pkey PRIMARY KEY (id); + + +-- +-- Name: articles articles_titleurl_unique; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.articles + ADD CONSTRAINT articles_titleurl_unique UNIQUE (titleurl); + + +-- +-- Name: bookmark_tag bookmark_tag_pkey; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.bookmark_tag + ADD CONSTRAINT bookmark_tag_pkey PRIMARY KEY (id); + + +-- +-- Name: bookmarks bookmarks_pkey; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.bookmarks + ADD CONSTRAINT bookmarks_pkey PRIMARY KEY (id); + + +-- +-- Name: clients clients_pkey; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.clients + ADD CONSTRAINT clients_pkey PRIMARY KEY (id); + + +-- +-- Name: contacts contacts_pkey; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.contacts + ADD CONSTRAINT contacts_pkey PRIMARY KEY (id); + + +-- +-- Name: failed_jobs failed_jobs_pkey; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.failed_jobs + ADD CONSTRAINT failed_jobs_pkey PRIMARY KEY (id); + + +-- +-- Name: failed_jobs failed_jobs_uuid_unique; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.failed_jobs + ADD CONSTRAINT failed_jobs_uuid_unique UNIQUE (uuid); + + +-- +-- Name: indie_web_users indie_web_users_me_unique; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.indie_web_users + ADD CONSTRAINT indie_web_users_me_unique UNIQUE (me); + + +-- +-- Name: indie_web_users indie_web_users_pkey; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.indie_web_users + ADD CONSTRAINT indie_web_users_pkey PRIMARY KEY (id); + + +-- +-- Name: likes likes_pkey; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.likes + ADD CONSTRAINT likes_pkey PRIMARY KEY (id); + + +-- +-- Name: media_endpoint media_endpoint_pkey; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.media_endpoint + ADD CONSTRAINT media_endpoint_pkey PRIMARY KEY (id); + + +-- +-- Name: media media_pkey; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.media + ADD CONSTRAINT media_pkey PRIMARY KEY (id); + + +-- +-- Name: migrations migrations_pkey; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.migrations + ADD CONSTRAINT migrations_pkey PRIMARY KEY (id); + + +-- +-- Name: note_tag note_tag_pkey; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.note_tag + ADD CONSTRAINT note_tag_pkey PRIMARY KEY (id); + + +-- +-- Name: notes notes_pkey; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.notes + ADD CONSTRAINT notes_pkey PRIMARY KEY (id); + + +-- +-- Name: personal_access_tokens personal_access_tokens_pkey; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.personal_access_tokens + ADD CONSTRAINT personal_access_tokens_pkey PRIMARY KEY (id); + + +-- +-- Name: personal_access_tokens personal_access_tokens_token_unique; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.personal_access_tokens + ADD CONSTRAINT personal_access_tokens_token_unique UNIQUE (token); + + +-- +-- Name: places places_pkey; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.places + ADD CONSTRAINT places_pkey PRIMARY KEY (id); + + +-- +-- Name: places places_slug_unique; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.places + ADD CONSTRAINT places_slug_unique UNIQUE (slug); + + +-- +-- Name: syndication_targets syndication_targets_pkey; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.syndication_targets + ADD CONSTRAINT syndication_targets_pkey PRIMARY KEY (id); + + +-- +-- Name: tags tags_pkey; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.tags + ADD CONSTRAINT tags_pkey PRIMARY KEY (id); + + +-- +-- Name: telescope_entries telescope_entries_pkey; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.telescope_entries + ADD CONSTRAINT telescope_entries_pkey PRIMARY KEY (sequence); + + +-- +-- Name: telescope_entries telescope_entries_uuid_unique; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.telescope_entries + ADD CONSTRAINT telescope_entries_uuid_unique UNIQUE (uuid); + + +-- +-- Name: users users_pkey; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.users + ADD CONSTRAINT users_pkey PRIMARY KEY (id); + + +-- +-- Name: webmentions webmentions_pkey; Type: CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.webmentions + ADD CONSTRAINT webmentions_pkey PRIMARY KEY (id); + + +-- +-- Name: media_endpoint_token_index; Type: INDEX; Schema: public; Owner: - +-- + +CREATE INDEX media_endpoint_token_index ON public.media_endpoint USING btree (token); + + +-- +-- Name: media_model_type_model_id_index; Type: INDEX; Schema: public; Owner: - +-- + +CREATE INDEX media_model_type_model_id_index ON public.media USING btree (model_type, model_id); + + +-- +-- Name: personal_access_tokens_tokenable_type_tokenable_id_index; Type: INDEX; Schema: public; Owner: - +-- + +CREATE INDEX personal_access_tokens_tokenable_type_tokenable_id_index ON public.personal_access_tokens USING btree (tokenable_type, tokenable_id); + + +-- +-- Name: places_external_urls_index; Type: INDEX; Schema: public; Owner: - +-- + +CREATE INDEX places_external_urls_index ON public.places USING btree (external_urls); + + +-- +-- Name: telescope_entries_batch_id_index; Type: INDEX; Schema: public; Owner: - +-- + +CREATE INDEX telescope_entries_batch_id_index ON public.telescope_entries USING btree (batch_id); + + +-- +-- Name: telescope_entries_family_hash_index; Type: INDEX; Schema: public; Owner: - +-- + +CREATE INDEX telescope_entries_family_hash_index ON public.telescope_entries USING btree (family_hash); + + +-- +-- Name: telescope_entries_tags_entry_uuid_tag_index; Type: INDEX; Schema: public; Owner: - +-- + +CREATE INDEX telescope_entries_tags_entry_uuid_tag_index ON public.telescope_entries_tags USING btree (entry_uuid, tag); + + +-- +-- Name: telescope_entries_tags_tag_index; Type: INDEX; Schema: public; Owner: - +-- + +CREATE INDEX telescope_entries_tags_tag_index ON public.telescope_entries_tags USING btree (tag); + + +-- +-- Name: telescope_entries_type_should_display_on_index_index; Type: INDEX; Schema: public; Owner: - +-- + +CREATE INDEX telescope_entries_type_should_display_on_index_index ON public.telescope_entries USING btree (type, should_display_on_index); + + +-- +-- Name: webmentions_mf2_index; Type: INDEX; Schema: public; Owner: - +-- + +CREATE INDEX webmentions_mf2_index ON public.webmentions USING btree (mf2); + + +-- +-- Name: bookmark_tag bookmark_tag_bookmark_id_foreign; Type: FK CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.bookmark_tag + ADD CONSTRAINT bookmark_tag_bookmark_id_foreign FOREIGN KEY (bookmark_id) REFERENCES public.bookmarks(id); + + +-- +-- Name: bookmark_tag bookmark_tag_tag_id_foreign; Type: FK CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.bookmark_tag + ADD CONSTRAINT bookmark_tag_tag_id_foreign FOREIGN KEY (tag_id) REFERENCES public.tags(id); + + +-- +-- Name: media_endpoint media_endpoint_note_id_foreign; Type: FK CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.media_endpoint + ADD CONSTRAINT media_endpoint_note_id_foreign FOREIGN KEY (note_id) REFERENCES public.notes(id); + + +-- +-- Name: note_tag note_tag_note_id_foreign; Type: FK CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.note_tag + ADD CONSTRAINT note_tag_note_id_foreign FOREIGN KEY (note_id) REFERENCES public.notes(id) ON DELETE CASCADE; + + +-- +-- Name: note_tag note_tag_tag_id_foreign; Type: FK CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.note_tag + ADD CONSTRAINT note_tag_tag_id_foreign FOREIGN KEY (tag_id) REFERENCES public.tags(id); + + +-- +-- Name: notes notes_place_id_foreign; Type: FK CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.notes + ADD CONSTRAINT notes_place_id_foreign FOREIGN KEY (place_id) REFERENCES public.places(id); + + +-- +-- Name: telescope_entries_tags telescope_entries_tags_entry_uuid_foreign; Type: FK CONSTRAINT; Schema: public; Owner: - +-- + +ALTER TABLE ONLY public.telescope_entries_tags + ADD CONSTRAINT telescope_entries_tags_entry_uuid_foreign FOREIGN KEY (entry_uuid) REFERENCES public.telescope_entries(uuid) ON DELETE CASCADE; + + +-- +-- PostgreSQL database dump complete +-- + +-- +-- PostgreSQL database dump +-- + +-- Dumped from database version 14.4 (Debian 14.4-1.pgdg110+1) +-- Dumped by pg_dump version 14.6 (Ubuntu 14.6-1.pgdg22.04+1) + +SET statement_timeout = 0; +SET lock_timeout = 0; +SET idle_in_transaction_session_timeout = 0; +SET client_encoding = 'UTF8'; +SET standard_conforming_strings = on; +SELECT pg_catalog.set_config('search_path', '', false); +SET check_function_bodies = false; +SET xmloption = content; +SET client_min_messages = warning; +SET row_security = off; + +-- +-- Data for Name: migrations; Type: TABLE DATA; Schema: public; Owner: - +-- + +COPY public.migrations (id, migration, batch) FROM stdin; +1 2015_02_28_132629_create_articles_table 1 +2 2015_02_28_144939_create_notes_table 1 +3 2015_03_02_084342_create_tags_table 1 +4 2015_03_02_084956_create_note_tag_table 1 +5 2015_03_02_105623_create_contacts_table 1 +6 2015_03_02_114340_create_web_mentions_table 1 +7 2015_07_17_111512_create_clients_table 1 +8 2015_10_08_155111_create_media_table 1 +9 2015_11_07_130637_create_places_table 1 +10 2015_11_19_221933_add_place_relation_to_notes 1 +11 2016_07_29_113150_add_jsonb_mf2_column_to_webmentions_table 1 +12 2016_09_30_214651_cascade_delete_note_tags 1 +13 2016_10_26_170858_add_facebook_url_column_to_notes 1 +14 2016_11_23_154939_add_facebook_to_contacts 1 +15 2016_12_05_204035_add_search_to_notes 1 +16 2016_12_28_160024_add_icon_to_places 1 +17 2017_03_09_155908_create_media_endpoint_table 1 +18 2017_03_28_130855_create_indie_web_users_table 1 +19 2017_04_25_203734_update_notes_table_add_swarm_url 1 +20 2017_05_12_135451_update_places_table_add_foursquare_column 1 +21 2017_06_11_193737_update_notes_table_add_instagram_url 1 +22 2017_06_27_164743_update_places_table_add_external_urls 1 +23 2017_08_09_181357_allow_empty_note_content 1 +24 2017_09_15_081131_update_media_endpoint_table_add_nullable_image_width_column 1 +25 2017_09_16_191741_create_likes_table 1 +26 2017_10_07_163425_create_bookmarks_table 1 +27 2017_10_07_164651_create_bookmark_tag_pivot_table 1 +28 2017_12_19_160117_update_models_reference_in_webmentions_table 1 +29 2018_08_08_100000_create_telescope_entries_table 1 +30 2019_03_20_181657_create_users_table 1 +31 2019_12_14_000001_create_personal_access_tokens_table 1 +32 2020_10_10_191546_add_latitude-longitude_columns 1 +33 2020_10_16_153324_remove_location_column 1 +34 2022_02_27_182404_remove_notes_searchable_tsvector 1 +35 2022_10_21_155721_create_syndication_targets_table 1 +36 2022_10_26_180903_add_mastodon_syndication_url 1 +37 2022_11_21_184127_remove_old_failed_jobs_table 1 +38 2022_11_21_185719_create_failed_jobs_table 1 +\. + + +-- +-- Name: migrations_id_seq; Type: SEQUENCE SET; Schema: public; Owner: - +-- + +SELECT pg_catalog.setval('public.migrations_id_seq', 38, true); + + +-- +-- PostgreSQL database dump complete +-- + diff --git a/database/seeders/ArticlesTableSeeder.php b/database/seeders/ArticlesTableSeeder.php index c61fa8b6..cbfd7a36 100644 --- a/database/seeders/ArticlesTableSeeder.php +++ b/database/seeders/ArticlesTableSeeder.php @@ -10,11 +10,9 @@ use Illuminate\Support\Facades\DB; class ArticlesTableSeeder extends Seeder { /** - * Run the database seeds. - * - * @return void + * Seed the articles table. */ - public function run() + public function run(): void { $now = Carbon::now()->subMonth()->subDays(5); $articleFirst = Article::create([ diff --git a/database/seeders/BookmarksTableSeeder.php b/database/seeders/BookmarksTableSeeder.php index 8e06aaca..baa3580f 100644 --- a/database/seeders/BookmarksTableSeeder.php +++ b/database/seeders/BookmarksTableSeeder.php @@ -9,11 +9,9 @@ use Illuminate\Database\Seeder; class BookmarksTableSeeder extends Seeder { /** - * Run the database seeds. - * - * @return void + * Seed the bookmarks table. */ - public function run() + public function run(): void { Bookmark::factory(10) ->has(Tag::factory()->count(1)) diff --git a/database/seeders/ClientsTableSeeder.php b/database/seeders/ClientsTableSeeder.php index 82a49f41..35dcb296 100644 --- a/database/seeders/ClientsTableSeeder.php +++ b/database/seeders/ClientsTableSeeder.php @@ -10,11 +10,9 @@ use Illuminate\Support\Facades\DB; class ClientsTableSeeder extends Seeder { /** - * Run the database seeds. - * - * @return void + * Seed the clients table. */ - public function run() + public function run(): void { DB::table('clients')->insert([ 'client_url' => 'https://jbl5.dev/notes/new', diff --git a/database/seeders/ContactsTableSeeder.php b/database/seeders/ContactsTableSeeder.php index 4ca526c5..328a039c 100644 --- a/database/seeders/ContactsTableSeeder.php +++ b/database/seeders/ContactsTableSeeder.php @@ -9,11 +9,9 @@ use Illuminate\FileSystem\FileSystem; class ContactsTableSeeder extends Seeder { /** - * Run the database seeds. - * - * @return void + * Seed the contacts table. */ - public function run() + public function run(): void { Contact::create([ 'nick' => 'tantek', diff --git a/database/seeders/DatabaseSeeder.php b/database/seeders/DatabaseSeeder.php index f4bad136..5117a89d 100644 --- a/database/seeders/DatabaseSeeder.php +++ b/database/seeders/DatabaseSeeder.php @@ -7,11 +7,9 @@ use Illuminate\Database\Seeder; class DatabaseSeeder extends Seeder { /** - * Run the database seeds. - * - * @return void + * Seed the application's database. */ - public function run() + public function run(): void { $this->call(ArticlesTableSeeder::class); $this->call(ClientsTableSeeder::class); diff --git a/database/seeders/LikesTableSeeder.php b/database/seeders/LikesTableSeeder.php index f01b4df0..dc6a36f3 100644 --- a/database/seeders/LikesTableSeeder.php +++ b/database/seeders/LikesTableSeeder.php @@ -11,11 +11,9 @@ use Illuminate\Support\Facades\DB; class LikesTableSeeder extends Seeder { /** - * Run the database seeds. - * - * @return void + * Seed the likes table. */ - public function run() + public function run(): void { Like::factory(10)->create(); diff --git a/database/seeders/NotesTableSeeder.php b/database/seeders/NotesTableSeeder.php index 7218b219..13b1a470 100644 --- a/database/seeders/NotesTableSeeder.php +++ b/database/seeders/NotesTableSeeder.php @@ -13,11 +13,9 @@ use SplFileInfo; class NotesTableSeeder extends Seeder { /** - * Run the database seeds. - * - * @return void + * Seed the notes table. */ - public function run() + public function run(): void { $now = Carbon::now()->subDays(rand(2, 5)); $noteTwitterReply = Note::create([ diff --git a/database/seeders/PlacesTableSeeder.php b/database/seeders/PlacesTableSeeder.php index 6bd7bc3c..44cb266f 100644 --- a/database/seeders/PlacesTableSeeder.php +++ b/database/seeders/PlacesTableSeeder.php @@ -8,11 +8,9 @@ use Illuminate\Database\Seeder; class PlacesTableSeeder extends Seeder { /** - * Run the database seeds. - * - * @return void + * Seed the places table. */ - public function run() + public function run(): void { $place = new Place(); $place->name = 'The Bridgewater Pub'; diff --git a/database/seeders/UsersTableSeeder.php b/database/seeders/UsersTableSeeder.php index bc03d593..d9e608e2 100644 --- a/database/seeders/UsersTableSeeder.php +++ b/database/seeders/UsersTableSeeder.php @@ -8,11 +8,9 @@ use Illuminate\Support\Facades\DB; class UsersTableSeeder extends Seeder { /** - * Run the database seeds. - * - * @return void + * Seed the users table. */ - public function run() + public function run(): void { DB::table('users')->insert([ 'name' => 'jonny', diff --git a/database/seeders/WebMentionsTableSeeder.php b/database/seeders/WebMentionsTableSeeder.php index d116b9c7..eb16e249 100644 --- a/database/seeders/WebMentionsTableSeeder.php +++ b/database/seeders/WebMentionsTableSeeder.php @@ -8,11 +8,9 @@ use Illuminate\Database\Seeder; class WebMentionsTableSeeder extends Seeder { /** - * Run the database seeds. - * - * @return void + * Seed the webmentions table. */ - public function run() + public function run(): void { // WebMention Aaron WebMention::create([ diff --git a/phpunit.xml b/phpunit.xml index 9594be5d..29e2843f 100644 --- a/phpunit.xml +++ b/phpunit.xml @@ -7,13 +7,21 @@ > - ./tests/Unit + ./tests/Unit - ./tests/Feature + ./tests/Feature + + + ./app + + + + + @@ -25,12 +33,4 @@ - - - ./app - - - - - diff --git a/routes/api.php b/routes/api.php index ae7df4d5..c9b0b965 100644 --- a/routes/api.php +++ b/routes/api.php @@ -8,11 +8,11 @@ use Illuminate\Http\Request; |-------------------------------------------------------------------------- | | Here is where you can register API routes for your application. These -| routes are loaded by the RouteServiceProvider within a group which -| is assigned the "api" middleware group. Enjoy building your API! +| routes are loaded by the RouteServiceProvider and all of them will +| be assigned to the "api" middleware group. Make something great! | */ -/*Route::middleware('auth:api')->get('/user', function (Request $request) { +/*Route::middleware('auth:sanctum')->get('/user', function (Request $request) { return $request->user(); });*/ diff --git a/routes/web.php b/routes/web.php index f721a2df..2a536f10 100644 --- a/routes/web.php +++ b/routes/web.php @@ -6,8 +6,8 @@ |-------------------------------------------------------------------------- | | Here is where you can register web routes for your application. These -| routes are loaded by the RouteServiceProvider within a group which -| contains the "web" middleware group. Now create something great! +| routes are loaded by the RouteServiceProvider and all of them will +| be assigned to the "web" middleware group. Make something great! | */ diff --git a/tests/CreatesApplication.php b/tests/CreatesApplication.php index 547152f6..cc683011 100644 --- a/tests/CreatesApplication.php +++ b/tests/CreatesApplication.php @@ -3,15 +3,14 @@ namespace Tests; use Illuminate\Contracts\Console\Kernel; +use Illuminate\Foundation\Application; trait CreatesApplication { /** * Creates the application. - * - * @return \Illuminate\Foundation\Application */ - public function createApplication() + public function createApplication(): Application { $app = require __DIR__.'/../bootstrap/app.php'; diff --git a/tests/Feature/Admin/AdminTest.php b/tests/Feature/Admin/AdminTest.php index 2d3f8f70..77c0ab08 100644 --- a/tests/Feature/Admin/AdminTest.php +++ b/tests/Feature/Admin/AdminTest.php @@ -10,7 +10,7 @@ use Tests\TestCase; class AdminTest extends TestCase { /** @test */ - public function adminPageRedirectsUnauthedUsersToLoginPage(): void + public function adminPageRedirectsUnauthorisedUsersToLoginPage(): void { $response = $this->get('/admin'); $response->assertRedirect('/login'); diff --git a/tests/TestToken.php b/tests/TestToken.php index 1e9e7c42..5b54d497 100644 --- a/tests/TestToken.php +++ b/tests/TestToken.php @@ -7,7 +7,7 @@ use Lcobucci\JWT\Configuration; trait TestToken { - public function getToken() + public function getToken(): string { $config = $this->app->make(Configuration::class); @@ -20,7 +20,7 @@ trait TestToken ->toString(); } - public function getTokenWithIncorrectScope() + public function getTokenWithIncorrectScope(): string { $config = $this->app->make(Configuration::class);