From e709239dc88baad27ca21f1c3df73528a911d55d Mon Sep 17 00:00:00 2001 From: Henry Whitaker Date: Sat, 8 Aug 2020 23:18:16 +0100 Subject: [PATCH] Updated files to v1.7.17 --- README.md | 2 +- conf/site/README.md | 2 +- .../Console/Commands/AcceptEULACommand.php | 2 +- .../Console/Commands/ClearQueueCommand.php | 2 +- conf/site/app/Console/Commands/GetConfig.php | 2 +- .../app/Console/Commands/SetSlackWebhook.php | 2 +- .../Console/Commands/SetTelegramOptions.php | 2 +- .../app/Console/Commands/SpeedtestCommand.php | 2 +- .../Commands/SpeedtestLatestCommand.php | 2 +- .../Commands/SpeedtestVersionCommand.php | 2 +- .../app/Console/Commands/TestNotification.php | 2 +- .../app/Events/SpeedtestCompleteEvent.php | 2 + conf/site/app/Helpers/BackupHelper.php | 4 +- conf/site/app/Helpers/SettingsHelper.php | 8 +- conf/site/app/Helpers/SpeedtestHelper.php | 13 +- conf/site/app/Helpers/UpdateHelper.php | 27 +- .../app/Http/Controllers/BackupController.php | 5 +- .../Http/Controllers/SettingsController.php | 17 +- .../Http/Controllers/SpeedtestController.php | 15 +- .../app/Http/Controllers/UpdateController.php | 15 +- .../site/app/Http/Middleware/Authenticate.php | 2 + .../app/Listeners/SpeedtestFailedListener.php | 1 + .../SpeedtestCompleteTelegram.php | 2 + .../Notifications/SpeedtestOverviewSlack.php | 2 + .../SpeedtestOverviewTelegram.php | 2 + conf/site/app/User.php | 2 +- conf/site/changelog.json | 6 + conf/site/composer.json | 1 + conf/site/composer.lock | 883 +++++++++++++++--- conf/site/config/speedtest.php | 6 +- conf/site/package-lock.json | 22 +- conf/site/package.json | 6 +- conf/site/phpstan.neon | 18 + 33 files changed, 888 insertions(+), 193 deletions(-) create mode 100644 conf/site/phpstan.neon diff --git a/README.md b/README.md index d29fe106..ef3e6e92 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Speedtest Tracker -[![Docker pulls](https://img.shields.io/docker/pulls/henrywhitaker3/speedtest-tracker?style=flat-square)](https://hub.docker.com/r/henrywhitaker3/speedtest-tracker) [![GitHub Workflow Status](https://img.shields.io/github/workflow/status/henrywhitaker3/Speedtest-Tracker/Stable?label=master&logo=github&style=flat-square)](https://github.com/henrywhitaker3/Speedtest-Tracker/actions) [![GitHub Workflow Status](https://img.shields.io/github/workflow/status/henrywhitaker3/Speedtest-Tracker/Dev?label=dev&logo=github&style=flat-square)](https://github.com/henrywhitaker3/Speedtest-Tracker/actions) [![last_commit](https://img.shields.io/github/last-commit/henrywhitaker3/Speedtest-Tracker?style=flat-square)](https://github.com/henrywhitaker3/Speedtest-Tracker/commits) [![issues](https://img.shields.io/github/issues/henrywhitaker3/Speedtest-Tracker?style=flat-square)](https://github.com/henrywhitaker3/Speedtest-Tracker/issues) [![commit_freq](https://img.shields.io/github/commit-activity/m/henrywhitaker3/Speedtest-Tracker?style=flat-square)](https://github.com/henrywhitaker3/Speedtest-Tracker/commits) ![version](https://img.shields.io/badge/version-v1.7.16-success?style=flat-square) [![license](https://img.shields.io/github/license/henrywhitaker3/Speedtest-Tracker?style=flat-square)](https://github.com/henrywhitaker3/Speedtest-Tracker/blob/master/LICENSE) +[![Docker pulls](https://img.shields.io/docker/pulls/henrywhitaker3/speedtest-tracker?style=flat-square)](https://hub.docker.com/r/henrywhitaker3/speedtest-tracker) [![GitHub Workflow Status](https://img.shields.io/github/workflow/status/henrywhitaker3/Speedtest-Tracker/Stable?label=master&logo=github&style=flat-square)](https://github.com/henrywhitaker3/Speedtest-Tracker/actions) [![GitHub Workflow Status](https://img.shields.io/github/workflow/status/henrywhitaker3/Speedtest-Tracker/Dev?label=dev&logo=github&style=flat-square)](https://github.com/henrywhitaker3/Speedtest-Tracker/actions) [![last_commit](https://img.shields.io/github/last-commit/henrywhitaker3/Speedtest-Tracker?style=flat-square)](https://github.com/henrywhitaker3/Speedtest-Tracker/commits) [![issues](https://img.shields.io/github/issues/henrywhitaker3/Speedtest-Tracker?style=flat-square)](https://github.com/henrywhitaker3/Speedtest-Tracker/issues) [![commit_freq](https://img.shields.io/github/commit-activity/m/henrywhitaker3/Speedtest-Tracker?style=flat-square)](https://github.com/henrywhitaker3/Speedtest-Tracker/commits) ![version](https://img.shields.io/badge/version-v1.7.17-success?style=flat-square) [![license](https://img.shields.io/github/license/henrywhitaker3/Speedtest-Tracker?style=flat-square)](https://github.com/henrywhitaker3/Speedtest-Tracker/blob/master/LICENSE) This program runs a speedtest check every hour and graphs the results. The back-end is written in [Laravel](https://laravel.com/) and the front-end uses [React](https://reactjs.org/). It uses [Ookla's Speedtest cli](https://www.speedtest.net/apps/cli) to get the data and uses [Chart.js](https://www.chartjs.org/) to plot the results. diff --git a/conf/site/README.md b/conf/site/README.md index 136e4966..c6d18a5a 100644 --- a/conf/site/README.md +++ b/conf/site/README.md @@ -1,6 +1,6 @@ # Speedtest Tracker -[![Docker pulls](https://img.shields.io/docker/pulls/henrywhitaker3/speedtest-tracker?style=flat-square)](https://hub.docker.com/r/henrywhitaker3/speedtest-tracker) [![GitHub Workflow Status](https://img.shields.io/github/workflow/status/henrywhitaker3/Speedtest-Tracker/Stable?label=master&logo=github&style=flat-square)](https://github.com/henrywhitaker3/Speedtest-Tracker/actions) [![GitHub Workflow Status](https://img.shields.io/github/workflow/status/henrywhitaker3/Speedtest-Tracker/Dev?label=dev&logo=github&style=flat-square)](https://github.com/henrywhitaker3/Speedtest-Tracker/actions) [![last_commit](https://img.shields.io/github/last-commit/henrywhitaker3/Speedtest-Tracker?style=flat-square)](https://github.com/henrywhitaker3/Speedtest-Tracker/commits) [![issues](https://img.shields.io/github/issues/henrywhitaker3/Speedtest-Tracker?style=flat-square)](https://github.com/henrywhitaker3/Speedtest-Tracker/issues) [![commit_freq](https://img.shields.io/github/commit-activity/m/henrywhitaker3/Speedtest-Tracker?style=flat-square)](https://github.com/henrywhitaker3/Speedtest-Tracker/commits) ![version](https://img.shields.io/badge/version-v1.7.16-success?style=flat-square) [![license](https://img.shields.io/github/license/henrywhitaker3/Speedtest-Tracker?style=flat-square)](https://github.com/henrywhitaker3/Speedtest-Tracker/blob/master/LICENSE) +[![Docker pulls](https://img.shields.io/docker/pulls/henrywhitaker3/speedtest-tracker?style=flat-square)](https://hub.docker.com/r/henrywhitaker3/speedtest-tracker) [![GitHub Workflow Status](https://img.shields.io/github/workflow/status/henrywhitaker3/Speedtest-Tracker/Stable?label=master&logo=github&style=flat-square)](https://github.com/henrywhitaker3/Speedtest-Tracker/actions) [![GitHub Workflow Status](https://img.shields.io/github/workflow/status/henrywhitaker3/Speedtest-Tracker/Dev?label=dev&logo=github&style=flat-square)](https://github.com/henrywhitaker3/Speedtest-Tracker/actions) [![last_commit](https://img.shields.io/github/last-commit/henrywhitaker3/Speedtest-Tracker?style=flat-square)](https://github.com/henrywhitaker3/Speedtest-Tracker/commits) [![issues](https://img.shields.io/github/issues/henrywhitaker3/Speedtest-Tracker?style=flat-square)](https://github.com/henrywhitaker3/Speedtest-Tracker/issues) [![commit_freq](https://img.shields.io/github/commit-activity/m/henrywhitaker3/Speedtest-Tracker?style=flat-square)](https://github.com/henrywhitaker3/Speedtest-Tracker/commits) ![version](https://img.shields.io/badge/version-v1.7.17-success?style=flat-square) [![license](https://img.shields.io/github/license/henrywhitaker3/Speedtest-Tracker?style=flat-square)](https://github.com/henrywhitaker3/Speedtest-Tracker/blob/master/LICENSE) This program runs a speedtest check every hour and graphs the results. The back-end is written in [Laravel](https://laravel.com/) and the front-end uses [React](https://reactjs.org/). It uses the [Ookla's speedtest cli](https://www.speedtest.net/apps/cli) package to get the data and uses [Chart.js](https://www.chartjs.org/) to plot the results. diff --git a/conf/site/app/Console/Commands/AcceptEULACommand.php b/conf/site/app/Console/Commands/AcceptEULACommand.php index 76d0fb6d..1a1f5747 100644 --- a/conf/site/app/Console/Commands/AcceptEULACommand.php +++ b/conf/site/app/Console/Commands/AcceptEULACommand.php @@ -34,7 +34,7 @@ class AcceptEULACommand extends Command /** * Execute the console command. * - * @return int + * @return void */ public function handle() { diff --git a/conf/site/app/Console/Commands/ClearQueueCommand.php b/conf/site/app/Console/Commands/ClearQueueCommand.php index 78dd42d8..84dfdb3b 100644 --- a/conf/site/app/Console/Commands/ClearQueueCommand.php +++ b/conf/site/app/Console/Commands/ClearQueueCommand.php @@ -34,7 +34,7 @@ class ClearQueueCommand extends Command /** * Execute the console command. * - * @return int + * @return void */ public function handle() { diff --git a/conf/site/app/Console/Commands/GetConfig.php b/conf/site/app/Console/Commands/GetConfig.php index dbfbbf7b..6182887a 100644 --- a/conf/site/app/Console/Commands/GetConfig.php +++ b/conf/site/app/Console/Commands/GetConfig.php @@ -34,7 +34,7 @@ class GetConfig extends Command /** * Execute the console command. * - * @return int + * @return void */ public function handle() { diff --git a/conf/site/app/Console/Commands/SetSlackWebhook.php b/conf/site/app/Console/Commands/SetSlackWebhook.php index f1fe25de..d67aaa76 100644 --- a/conf/site/app/Console/Commands/SetSlackWebhook.php +++ b/conf/site/app/Console/Commands/SetSlackWebhook.php @@ -34,7 +34,7 @@ class SetSlackWebhook extends Command /** * Execute the console command. * - * @return int + * @return void */ public function handle() { diff --git a/conf/site/app/Console/Commands/SetTelegramOptions.php b/conf/site/app/Console/Commands/SetTelegramOptions.php index c32715d1..b66ffaed 100644 --- a/conf/site/app/Console/Commands/SetTelegramOptions.php +++ b/conf/site/app/Console/Commands/SetTelegramOptions.php @@ -36,7 +36,7 @@ class SetTelegramOptions extends Command /** * Execute the console command. * - * @return int + * @return void */ public function handle() { diff --git a/conf/site/app/Console/Commands/SpeedtestCommand.php b/conf/site/app/Console/Commands/SpeedtestCommand.php index cf1dc1ae..27b7fa9a 100644 --- a/conf/site/app/Console/Commands/SpeedtestCommand.php +++ b/conf/site/app/Console/Commands/SpeedtestCommand.php @@ -34,7 +34,7 @@ class SpeedtestCommand extends Command /** * Runs a speedtest synchroonously and displays the results.. * - * @return null + * @return void */ public function handle() { diff --git a/conf/site/app/Console/Commands/SpeedtestLatestCommand.php b/conf/site/app/Console/Commands/SpeedtestLatestCommand.php index 57d04e55..e76971d8 100644 --- a/conf/site/app/Console/Commands/SpeedtestLatestCommand.php +++ b/conf/site/app/Console/Commands/SpeedtestLatestCommand.php @@ -35,7 +35,7 @@ class SpeedtestLatestCommand extends Command /** * Prints the latest speedtest values. * - * @return null + * @return void */ public function handle() { diff --git a/conf/site/app/Console/Commands/SpeedtestVersionCommand.php b/conf/site/app/Console/Commands/SpeedtestVersionCommand.php index 5d962b6f..c3617090 100644 --- a/conf/site/app/Console/Commands/SpeedtestVersionCommand.php +++ b/conf/site/app/Console/Commands/SpeedtestVersionCommand.php @@ -33,7 +33,7 @@ class SpeedtestVersionCommand extends Command /** * Execute the console command. * - * @return mixed + * @return void */ public function handle() { diff --git a/conf/site/app/Console/Commands/TestNotification.php b/conf/site/app/Console/Commands/TestNotification.php index c1796762..7018fec4 100644 --- a/conf/site/app/Console/Commands/TestNotification.php +++ b/conf/site/app/Console/Commands/TestNotification.php @@ -34,7 +34,7 @@ class TestNotification extends Command /** * Execute the console command. * - * @return int + * @return void */ public function handle() { diff --git a/conf/site/app/Events/SpeedtestCompleteEvent.php b/conf/site/app/Events/SpeedtestCompleteEvent.php index bcda12c5..84af38b5 100644 --- a/conf/site/app/Events/SpeedtestCompleteEvent.php +++ b/conf/site/app/Events/SpeedtestCompleteEvent.php @@ -15,6 +15,8 @@ class SpeedtestCompleteEvent { use Dispatchable, InteractsWithSockets, SerializesModels; + public $speedtest; + /** * Create a new event instance. * diff --git a/conf/site/app/Helpers/BackupHelper.php b/conf/site/app/Helpers/BackupHelper.php index 49708421..798408db 100644 --- a/conf/site/app/Helpers/BackupHelper.php +++ b/conf/site/app/Helpers/BackupHelper.php @@ -55,7 +55,7 @@ class BackupHelper { * * @param array|string $array Backup data * @param string $format json|csv - * @return boolean + * @return bool */ public static function restore($array, $format) { @@ -101,5 +101,7 @@ class BackupHelper { return true; } + + return false; } } diff --git a/conf/site/app/Helpers/SettingsHelper.php b/conf/site/app/Helpers/SettingsHelper.php index 8afd637d..ce209d10 100644 --- a/conf/site/app/Helpers/SettingsHelper.php +++ b/conf/site/app/Helpers/SettingsHelper.php @@ -12,7 +12,7 @@ class SettingsHelper { * Get a Setting object by name * * @param String $name The name field in the setting table - * @return \App\Setting|boolean $name The Setting object. Returns false if no mathcing obj. + * @return \App\Setting|bool|array $name The Setting object. Returns false if no mathcing obj. */ public static function get(String $name) { @@ -32,7 +32,7 @@ class SettingsHelper { * Create / update value for Setting object. * * @param String $name Name of setting - * @param String $value Value of setting + * @param String|bool $value Value of setting * @return \App\Setting */ public static function set(String $name, $value) @@ -153,7 +153,7 @@ class SettingsHelper { * Send test notification to agents * * @param boolean|string $agent - * @return void + * @return bool */ public static function testNotification($agent = true) { @@ -168,5 +168,7 @@ class SettingsHelper { event(new TestNotificationEvent([ $agent ])); return true; } + + return false; } } diff --git a/conf/site/app/Helpers/SpeedtestHelper.php b/conf/site/app/Helpers/SpeedtestHelper.php index 4793b990..4abf88a4 100644 --- a/conf/site/app/Helpers/SpeedtestHelper.php +++ b/conf/site/app/Helpers/SpeedtestHelper.php @@ -17,7 +17,7 @@ class SpeedtestHelper { * Runs/processes speedtest output to created a Speedtest object * * @param boolean|string $output If false, new speedtest runs. If anything else, will try to parse as JSON for speedtest results. - * @return \App\Speedtest|boolean + * @return \App\Speedtest|bool */ public static function runSpeedtest($output = false, $scheduled = true) { @@ -61,7 +61,7 @@ class SpeedtestHelper { ]); } - if(!isset($test) || $test == false) { + if($test == false) { return false; } @@ -142,14 +142,14 @@ class SpeedtestHelper { /** * Parses network speeds and return converted to Mbps * - * @param array $input + * @param string $input * @return array */ public static function parseUnits($input) { $input = explode(' ', $input); - $val = $input[0]; + $val = (float)$input[0]; $unit = explode('/', $input[1])[0]; switch($unit) { @@ -256,7 +256,7 @@ class SpeedtestHelper { /** * Create a backup of the SQLite database * - * @return boolean + * @return null|boolean */ public static function dbBackup() { @@ -277,7 +277,7 @@ class SpeedtestHelper { /** * Delete all speedtests from the database * - * @return boolean|string + * @return array */ public static function deleteAll() { @@ -290,7 +290,6 @@ class SpeedtestHelper { 'success' => true, ]; } - } return [ diff --git a/conf/site/app/Helpers/UpdateHelper.php b/conf/site/app/Helpers/UpdateHelper.php index d14cc551..65655039 100644 --- a/conf/site/app/Helpers/UpdateHelper.php +++ b/conf/site/app/Helpers/UpdateHelper.php @@ -13,38 +13,52 @@ class UpdateHelper { /** * URL of updates * - * @var string + * @var string|bool */ public $url; /** * Current app version number * - * @var string + * @var string|bool */ public $currentVersion; + /** + * Latest app version number + * + * @var string|bool + */ + public $latestVersion; + /** * Username of GitHub repo * - * @var string + * @var string|bool */ public $user; /** * Name of GitHub repo * - * @var string + * @var string|bool */ public $repo; /** * Branch of GitHub repo * - * @var string + * @var string|bool */ public $branch; + /** + * Store download + * + * @var string|null + */ + public $download; + function __construct() { $this->currentVersion = config('speedtest.version'); $this->user = config('speedtest.user'); @@ -87,7 +101,7 @@ class UpdateHelper { /** * Gets the latest version number from GitHub * - * @return array [ repo, branch, version ] + * @return array|bool [ repo, branch, version ] */ public function checkLatestVersion() { @@ -256,7 +270,6 @@ class UpdateHelper { $zip->open($backupZip, ZipArchive::CREATE | ZipArchive::OVERWRITE); // Create recursive directory iterator - /** @var SplFileInfo[] $files */ $files = new RecursiveIteratorIterator( new RecursiveDirectoryIterator($rootPath), RecursiveIteratorIterator::LEAVES_ONLY diff --git a/conf/site/app/Http/Controllers/BackupController.php b/conf/site/app/Http/Controllers/BackupController.php index 0354151e..d58e7663 100644 --- a/conf/site/app/Http/Controllers/BackupController.php +++ b/conf/site/app/Http/Controllers/BackupController.php @@ -7,6 +7,7 @@ use DateTime; use Illuminate\Http\Request; use Illuminate\Support\Facades\Storage; use Illuminate\Support\Facades\Validator; +use Illuminate\Http\JsonResponse; class BackupController extends Controller { @@ -15,7 +16,7 @@ class BackupController extends Controller * Get backup of speedtests * * @param Request $request - * @return file + * @return mixed|JsonResponse */ public function backup(Request $request) { @@ -36,7 +37,7 @@ class BackupController extends Controller * Retore from a backup * * @param Request $request - * @return Response + * @return JsonResponse */ public function restore(Request $request) { diff --git a/conf/site/app/Http/Controllers/SettingsController.php b/conf/site/app/Http/Controllers/SettingsController.php index 11ad35d3..4744bdd4 100644 --- a/conf/site/app/Http/Controllers/SettingsController.php +++ b/conf/site/app/Http/Controllers/SettingsController.php @@ -8,6 +8,8 @@ use App\Setting; use Illuminate\Http\Request; use Illuminate\Support\Facades\Log; use Illuminate\Support\Facades\Validator; +use Illuminate\Http\JsonResponse; +use Illuminate\Support\Collection; class SettingsController extends Controller { @@ -15,7 +17,7 @@ class SettingsController extends Controller /** * Return all settings * - * @return array + * @return Collection */ public function index() { @@ -37,7 +39,7 @@ class SettingsController extends Controller * Store/update a setting * * @param Request $request - * @return Response + * @return JsonResponse */ public function store(Request $request) { @@ -72,7 +74,7 @@ class SettingsController extends Controller * Bulk store/update a setting * * @param Request $request - * @return Response + * @return JsonResponse */ public function bulkStore(Request $request) { @@ -92,11 +94,10 @@ class SettingsController extends Controller $settings = []; foreach($request->data as $d) { if(!isset($d['value']) || $d['value'] == null) { - $d['value'] = ''; + $d['value'] = ''; } if($d['name'] == 'speedtest_overview_time') { - $ok = [ '00', '01', '02', '03', '04', '05', '06', '07', '08', '09', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '20', '21', '22', '23' ]; if(!in_array($d['value'], $ok)) { return response()->json([ @@ -135,6 +136,12 @@ class SettingsController extends Controller return SettingsHelper::getConfig(); } + + /** + * Trigger a test of all notification agents + * + * @return JsonResponse + */ public function testNotification() { SettingsHelper::testNotification(); diff --git a/conf/site/app/Http/Controllers/SpeedtestController.php b/conf/site/app/Http/Controllers/SpeedtestController.php index c814a673..b1ac3234 100644 --- a/conf/site/app/Http/Controllers/SpeedtestController.php +++ b/conf/site/app/Http/Controllers/SpeedtestController.php @@ -11,6 +11,7 @@ use Illuminate\Http\Request; use Illuminate\Support\Facades\Cache; use Illuminate\Support\Facades\DB; use Illuminate\Support\Facades\Validator; +use Illuminate\Http\JsonResponse; class SpeedtestController extends Controller { @@ -18,7 +19,7 @@ class SpeedtestController extends Controller /** * Returns paginated list of speedtests * - * @return Response + * @return JsonResponse */ public function index() { @@ -35,7 +36,7 @@ class SpeedtestController extends Controller * Returns speedtest going back 'x' days * * @param int $days - * @return void + * @return JsonResponse */ public function time($days) { @@ -71,7 +72,7 @@ class SpeedtestController extends Controller * Returns speedtest failure rate going back 'x' days * * @param int $days - * @return void + * @return JsonResponse */ public function fail($days) { @@ -100,7 +101,7 @@ class SpeedtestController extends Controller /** * Return latest speedtest * - * @return Response + * @return JsonResponse */ public function latest() { @@ -130,7 +131,7 @@ class SpeedtestController extends Controller /** * Queue a new speedtest * - * @return Response + * @return JsonResponse */ public function run() { @@ -151,7 +152,7 @@ class SpeedtestController extends Controller /** * Delete all speedtests from db * - * @return Response + * @return JsonResponse */ public function deleteAll() { @@ -175,7 +176,7 @@ class SpeedtestController extends Controller * Delete a specific speedtest from the database * * @param Speedtest $speedtest - * @return boolean + * @return JsonResponse */ public function delete(Speedtest $speedtest) { diff --git a/conf/site/app/Http/Controllers/UpdateController.php b/conf/site/app/Http/Controllers/UpdateController.php index ed8bbe31..c6544a6e 100644 --- a/conf/site/app/Http/Controllers/UpdateController.php +++ b/conf/site/app/Http/Controllers/UpdateController.php @@ -5,6 +5,7 @@ namespace App\Http\Controllers; use Exception; use Updater; use Illuminate\Http\Request; +use Illuminate\Http\JsonResponse; class UpdateController extends Controller { @@ -12,7 +13,7 @@ class UpdateController extends Controller /** * Check for new update * - * @return Response + * @return JsonResponse */ public function checkForUpdate() { @@ -25,7 +26,7 @@ class UpdateController extends Controller /** * Download new update * - * @return Response + * @return JsonResponse */ public function downloadUpdate() { @@ -47,7 +48,7 @@ class UpdateController extends Controller /** * Trigger update extraction * - * @return Response + * @return JsonResponse */ public function extractUpdate() { @@ -69,22 +70,22 @@ class UpdateController extends Controller /** * Trigger update file move * - * @return Response + * @return JsonResponse */ public function moveUpdate() { - $cp = Updater::updateFiles(); + Updater::updateFiles(); return response()->json([ 'method' => 'copy latest version', - 'success' => $cp, + 'success' => null, ], 200); } /** * Get local changelog * - * @return Response + * @return JsonResponse */ public function changelog() { diff --git a/conf/site/app/Http/Middleware/Authenticate.php b/conf/site/app/Http/Middleware/Authenticate.php index 67c7dafc..69389c33 100644 --- a/conf/site/app/Http/Middleware/Authenticate.php +++ b/conf/site/app/Http/Middleware/Authenticate.php @@ -17,5 +17,7 @@ class Authenticate extends Middleware if (! $request->expectsJson()) { return route('auth.login'); } + + return null; } } diff --git a/conf/site/app/Listeners/SpeedtestFailedListener.php b/conf/site/app/Listeners/SpeedtestFailedListener.php index f6a52a07..d3111d74 100644 --- a/conf/site/app/Listeners/SpeedtestFailedListener.php +++ b/conf/site/app/Listeners/SpeedtestFailedListener.php @@ -10,6 +10,7 @@ use Illuminate\Contracts\Queue\ShouldQueue; use Illuminate\Queue\InteractsWithQueue; use Illuminate\Support\Facades\Log; use Illuminate\Support\Facades\Notification; +use NotificationChannels\Telegram\TelegramChannel; class SpeedtestFailedListener { diff --git a/conf/site/app/Notifications/SpeedtestCompleteTelegram.php b/conf/site/app/Notifications/SpeedtestCompleteTelegram.php index 591d1117..a512c662 100644 --- a/conf/site/app/Notifications/SpeedtestCompleteTelegram.php +++ b/conf/site/app/Notifications/SpeedtestCompleteTelegram.php @@ -14,6 +14,8 @@ class SpeedtestCompleteTelegram extends Notification { use Queueable; + public $speedtest; + /** * Create a new notification instance. * diff --git a/conf/site/app/Notifications/SpeedtestOverviewSlack.php b/conf/site/app/Notifications/SpeedtestOverviewSlack.php index f30beb96..cf046ba3 100644 --- a/conf/site/app/Notifications/SpeedtestOverviewSlack.php +++ b/conf/site/app/Notifications/SpeedtestOverviewSlack.php @@ -12,6 +12,8 @@ class SpeedtestOverviewSlack extends Notification { use Queueable; + public $data; + /** * Create a new notification instance. * diff --git a/conf/site/app/Notifications/SpeedtestOverviewTelegram.php b/conf/site/app/Notifications/SpeedtestOverviewTelegram.php index 3a8a2964..89415f4d 100644 --- a/conf/site/app/Notifications/SpeedtestOverviewTelegram.php +++ b/conf/site/app/Notifications/SpeedtestOverviewTelegram.php @@ -14,6 +14,8 @@ class SpeedtestOverviewTelegram extends Notification { use Queueable; + public $data; + /** * Create a new notification instance. * diff --git a/conf/site/app/User.php b/conf/site/app/User.php index c9ad0f1c..2f5cf899 100644 --- a/conf/site/app/User.php +++ b/conf/site/app/User.php @@ -78,7 +78,7 @@ class User extends Authenticatable implements JWTSubject /** * Returns a user's login sessions * - * @return array + * @return mixed */ public function sessions() { diff --git a/conf/site/changelog.json b/conf/site/changelog.json index 61970821..7c1303d7 100644 --- a/conf/site/changelog.json +++ b/conf/site/changelog.json @@ -1,4 +1,10 @@ { + "1.7.17": [ + { + "description": "Updated dependencies.", + "link": "" + } + ], "1.7.16": [ { "description": "Updated dependencies.", diff --git a/conf/site/composer.json b/conf/site/composer.json index 4105f9cb..c3720bd3 100644 --- a/conf/site/composer.json +++ b/conf/site/composer.json @@ -26,6 +26,7 @@ "fzaninotto/faker": "^1.9.1", "mockery/mockery": "^1.3.1", "nunomaduro/collision": "^4.1", + "nunomaduro/larastan": "^0.6.2", "phpunit/phpunit": "^8.5" }, "config": { diff --git a/conf/site/composer.lock b/conf/site/composer.lock index 0479c973..a66d59bf 100644 --- a/conf/site/composer.lock +++ b/conf/site/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": "d1d54df76d42dd6744e4fb47afdf6045", + "content-hash": "eee4cd81905b1464677cd0295e867901", "packages": [ { "name": "asm89/stack-cors", @@ -102,12 +102,6 @@ "brick", "math" ], - "funding": [ - { - "url": "https://tidelift.com/funding/github/packagist/brick/math", - "type": "tidelift" - } - ], "time": "2020-04-15T15:59:35+00:00" }, { @@ -498,20 +492,6 @@ "uppercase", "words" ], - "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%2Finflector", - "type": "tidelift" - } - ], "time": "2020-05-29T15:13:26+00:00" }, { @@ -574,20 +554,6 @@ "parser", "php" ], - "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%2Flexer", - "type": "tidelift" - } - ], "time": "2020-05-25T17:44:05+00:00" }, { @@ -824,12 +790,6 @@ "crossdomain", "laravel" ], - "funding": [ - { - "url": "https://github.com/barryvdh", - "type": "github" - } - ], "time": "2020-05-31T07:30:16+00:00" }, { @@ -1098,16 +1058,16 @@ }, { "name": "laravel/framework", - "version": "v7.22.4", + "version": "v7.23.2", "source": { "type": "git", "url": "https://github.com/laravel/framework.git", - "reference": "30e851a2b3a2af73fba0b7f4fa22b04260db98e7" + "reference": "75792f4c6945749046d4ec1ce560b04640d36b99" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laravel/framework/zipball/30e851a2b3a2af73fba0b7f4fa22b04260db98e7", - "reference": "30e851a2b3a2af73fba0b7f4fa22b04260db98e7", + "url": "https://api.github.com/repos/laravel/framework/zipball/75792f4c6945749046d4ec1ce560b04640d36b99", + "reference": "75792f4c6945749046d4ec1ce560b04640d36b99", "shasum": "" }, "require": { @@ -1251,7 +1211,7 @@ "framework", "laravel" ], - "time": "2020-07-27T18:25:06+00:00" + "time": "2020-08-06T14:56:13+00:00" }, { "name": "laravel/slack-notification-channel", @@ -1825,16 +1785,16 @@ }, { "name": "nesbot/carbon", - "version": "2.37.0", + "version": "2.38.0", "source": { "type": "git", "url": "https://github.com/briannesbitt/Carbon.git", - "reference": "1f61206de973d67f36ce50f041c792ddac663c3e" + "reference": "d8f6a6a91d1eb9304527b040500f61923e97674b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/1f61206de973d67f36ce50f041c792ddac663c3e", - "reference": "1f61206de973d67f36ce50f041c792ddac663c3e", + "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/d8f6a6a91d1eb9304527b040500f61923e97674b", + "reference": "d8f6a6a91d1eb9304527b040500f61923e97674b", "shasum": "" }, "require": { @@ -1849,7 +1809,7 @@ "kylekatarnls/multi-tester": "^2.0", "phpmd/phpmd": "^2.8", "phpstan/extension-installer": "^1.0", - "phpstan/phpstan": "^0.12.30", + "phpstan/phpstan": "^0.12.35", "phpunit/phpunit": "^7.5 || ^8.0", "squizlabs/php_codesniffer": "^3.4" }, @@ -1910,7 +1870,7 @@ "type": "tidelift" } ], - "time": "2020-07-28T06:04:54+00:00" + "time": "2020-08-04T19:12:46+00:00" }, { "name": "nikic/php-parser", @@ -2599,16 +2559,16 @@ }, { "name": "ramsey/uuid", - "version": "4.0.1", + "version": "4.1.0", "source": { "type": "git", "url": "https://github.com/ramsey/uuid.git", - "reference": "ba8fff1d3abb8bb4d35a135ed22a31c6ef3ede3d" + "reference": "988dbefc7878d0a35f12afb4df1f7dd0bd153c43" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/ramsey/uuid/zipball/ba8fff1d3abb8bb4d35a135ed22a31c6ef3ede3d", - "reference": "ba8fff1d3abb8bb4d35a135ed22a31c6ef3ede3d", + "url": "https://api.github.com/repos/ramsey/uuid/zipball/988dbefc7878d0a35f12afb4df1f7dd0bd153c43", + "reference": "988dbefc7878d0a35f12afb4df1f7dd0bd153c43", "shasum": "" }, "require": { @@ -2623,7 +2583,7 @@ }, "require-dev": { "codeception/aspect-mock": "^3", - "dealerdirect/phpcodesniffer-composer-installer": "^0.6.2", + "dealerdirect/phpcodesniffer-composer-installer": "^0.6.2 || ^0.7.0", "doctrine/annotations": "^1.8", "goaop/framework": "^2", "mockery/mockery": "^1.3", @@ -2632,8 +2592,8 @@ "php-mock/php-mock-mockery": "^1.3", "php-mock/php-mock-phpunit": "^2.5", "php-parallel-lint/php-parallel-lint": "^1.1", + "phpbench/phpbench": "^0.17.1", "phpstan/extension-installer": "^1.0", - "phpstan/phpdoc-parser": "0.4.3", "phpstan/phpstan": "^0.12", "phpstan/phpstan-mockery": "^0.12", "phpstan/phpstan-phpunit": "^0.12", @@ -2682,7 +2642,7 @@ "type": "github" } ], - "time": "2020-03-29T20:13:32+00:00" + "time": "2020-07-28T16:51:01+00:00" }, { "name": "swiftmailer/swiftmailer", @@ -3533,7 +3493,7 @@ }, { "name": "symfony/polyfill-ctype", - "version": "v1.18.0", + "version": "v1.18.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-ctype.git", @@ -3609,7 +3569,7 @@ }, { "name": "symfony/polyfill-iconv", - "version": "v1.18.0", + "version": "v1.18.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-iconv.git", @@ -3686,7 +3646,7 @@ }, { "name": "symfony/polyfill-intl-grapheme", - "version": "v1.18.0", + "version": "v1.18.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-grapheme.git", @@ -3764,16 +3724,16 @@ }, { "name": "symfony/polyfill-intl-idn", - "version": "v1.18.0", + "version": "v1.18.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-idn.git", - "reference": "bc6549d068d0160e0f10f7a5a23c7d1406b95ebe" + "reference": "5dcab1bc7146cf8c1beaa4502a3d9be344334251" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-intl-idn/zipball/bc6549d068d0160e0f10f7a5a23c7d1406b95ebe", - "reference": "bc6549d068d0160e0f10f7a5a23c7d1406b95ebe", + "url": "https://api.github.com/repos/symfony/polyfill-intl-idn/zipball/5dcab1bc7146cf8c1beaa4502a3d9be344334251", + "reference": "5dcab1bc7146cf8c1beaa4502a3d9be344334251", "shasum": "" }, "require": { @@ -3845,11 +3805,11 @@ "type": "tidelift" } ], - "time": "2020-07-14T12:35:20+00:00" + "time": "2020-08-04T06:02:08+00:00" }, { "name": "symfony/polyfill-intl-normalizer", - "version": "v1.18.0", + "version": "v1.18.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-normalizer.git", @@ -3930,7 +3890,7 @@ }, { "name": "symfony/polyfill-mbstring", - "version": "v1.18.0", + "version": "v1.18.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-mbstring.git", @@ -4059,25 +4019,11 @@ "portable", "shim" ], - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], "time": "2020-03-09T19:04:49+00:00" }, { "name": "symfony/polyfill-php70", - "version": "v1.18.0", + "version": "v1.18.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php70.git", @@ -4154,7 +4100,7 @@ }, { "name": "symfony/polyfill-php72", - "version": "v1.18.0", + "version": "v1.18.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php72.git", @@ -4227,7 +4173,7 @@ }, { "name": "symfony/polyfill-php73", - "version": "v1.18.0", + "version": "v1.18.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php73.git", @@ -4303,7 +4249,7 @@ }, { "name": "symfony/polyfill-php80", - "version": "v1.18.0", + "version": "v1.18.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php80.git", @@ -4431,20 +4377,6 @@ "polyfill", "shim" ], - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], "time": "2020-03-02T11:55:35+00:00" }, { @@ -5142,12 +5074,6 @@ "jwt", "laravel" ], - "funding": [ - { - "url": "https://www.patreon.com/seantymon", - "type": "patreon" - } - ], "time": "2020-03-04T11:21:28+00:00" }, { @@ -5296,6 +5222,359 @@ } ], "packages-dev": [ + { + "name": "composer/ca-bundle", + "version": "1.2.7", + "source": { + "type": "git", + "url": "https://github.com/composer/ca-bundle.git", + "reference": "95c63ab2117a72f48f5a55da9740a3273d45b7fd" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/composer/ca-bundle/zipball/95c63ab2117a72f48f5a55da9740a3273d45b7fd", + "reference": "95c63ab2117a72f48f5a55da9740a3273d45b7fd", + "shasum": "" + }, + "require": { + "ext-openssl": "*", + "ext-pcre": "*", + "php": "^5.3.2 || ^7.0 || ^8.0" + }, + "require-dev": { + "phpunit/phpunit": "^4.8.35 || ^5.7 || 6.5 - 8", + "psr/log": "^1.0", + "symfony/process": "^2.5 || ^3.0 || ^4.0 || ^5.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.x-dev" + } + }, + "autoload": { + "psr-4": { + "Composer\\CaBundle\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Jordi Boggiano", + "email": "j.boggiano@seld.be", + "homepage": "http://seld.be" + } + ], + "description": "Lets you find a path to the system CA bundle, and includes a fallback to the Mozilla CA bundle.", + "keywords": [ + "cabundle", + "cacert", + "certificate", + "ssl", + "tls" + ], + "funding": [ + { + "url": "https://packagist.com", + "type": "custom" + }, + { + "url": "https://tidelift.com/funding/github/packagist/composer/composer", + "type": "tidelift" + } + ], + "time": "2020-04-08T08:27:21+00:00" + }, + { + "name": "composer/composer", + "version": "1.10.10", + "source": { + "type": "git", + "url": "https://github.com/composer/composer.git", + "reference": "32966a3b1d48bc01472a8321fd6472b44fad033a" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/composer/composer/zipball/32966a3b1d48bc01472a8321fd6472b44fad033a", + "reference": "32966a3b1d48bc01472a8321fd6472b44fad033a", + "shasum": "" + }, + "require": { + "composer/ca-bundle": "^1.0", + "composer/semver": "^1.0", + "composer/spdx-licenses": "^1.2", + "composer/xdebug-handler": "^1.1", + "justinrainbow/json-schema": "^5.2.10", + "php": "^5.3.2 || ^7.0", + "psr/log": "^1.0", + "seld/jsonlint": "^1.4", + "seld/phar-utils": "^1.0", + "symfony/console": "^2.7 || ^3.0 || ^4.0 || ^5.0", + "symfony/filesystem": "^2.7 || ^3.0 || ^4.0 || ^5.0", + "symfony/finder": "^2.7 || ^3.0 || ^4.0 || ^5.0", + "symfony/process": "^2.7 || ^3.0 || ^4.0 || ^5.0" + }, + "conflict": { + "symfony/console": "2.8.38" + }, + "require-dev": { + "phpspec/prophecy": "^1.10", + "symfony/phpunit-bridge": "^4.2" + }, + "suggest": { + "ext-openssl": "Enabling the openssl extension allows you to access https URLs for repositories and packages", + "ext-zip": "Enabling the zip extension allows you to unzip archives", + "ext-zlib": "Allow gzip compression of HTTP requests" + }, + "bin": [ + "bin/composer" + ], + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.10-dev" + } + }, + "autoload": { + "psr-4": { + "Composer\\": "src/Composer" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nils Adermann", + "email": "naderman@naderman.de", + "homepage": "http://www.naderman.de" + }, + { + "name": "Jordi Boggiano", + "email": "j.boggiano@seld.be", + "homepage": "http://seld.be" + } + ], + "description": "Composer helps you declare, manage and install dependencies of PHP projects. It ensures you have the right stack everywhere.", + "homepage": "https://getcomposer.org/", + "keywords": [ + "autoload", + "dependency", + "package" + ], + "funding": [ + { + "url": "https://packagist.com", + "type": "custom" + }, + { + "url": "https://github.com/composer", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/composer/composer", + "type": "tidelift" + } + ], + "time": "2020-08-03T09:35:19+00:00" + }, + { + "name": "composer/semver", + "version": "1.5.1", + "source": { + "type": "git", + "url": "https://github.com/composer/semver.git", + "reference": "c6bea70230ef4dd483e6bbcab6005f682ed3a8de" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/composer/semver/zipball/c6bea70230ef4dd483e6bbcab6005f682ed3a8de", + "reference": "c6bea70230ef4dd483e6bbcab6005f682ed3a8de", + "shasum": "" + }, + "require": { + "php": "^5.3.2 || ^7.0" + }, + "require-dev": { + "phpunit/phpunit": "^4.5 || ^5.0.5" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.x-dev" + } + }, + "autoload": { + "psr-4": { + "Composer\\Semver\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nils Adermann", + "email": "naderman@naderman.de", + "homepage": "http://www.naderman.de" + }, + { + "name": "Jordi Boggiano", + "email": "j.boggiano@seld.be", + "homepage": "http://seld.be" + }, + { + "name": "Rob Bast", + "email": "rob.bast@gmail.com", + "homepage": "http://robbast.nl" + } + ], + "description": "Semver library that offers utilities, version constraint parsing and validation.", + "keywords": [ + "semantic", + "semver", + "validation", + "versioning" + ], + "time": "2020-01-13T12:06:48+00:00" + }, + { + "name": "composer/spdx-licenses", + "version": "1.5.4", + "source": { + "type": "git", + "url": "https://github.com/composer/spdx-licenses.git", + "reference": "6946f785871e2314c60b4524851f3702ea4f2223" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/composer/spdx-licenses/zipball/6946f785871e2314c60b4524851f3702ea4f2223", + "reference": "6946f785871e2314c60b4524851f3702ea4f2223", + "shasum": "" + }, + "require": { + "php": "^5.3.2 || ^7.0 || ^8.0" + }, + "require-dev": { + "phpunit/phpunit": "^4.8.35 || ^5.7 || 6.5 - 7" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.x-dev" + } + }, + "autoload": { + "psr-4": { + "Composer\\Spdx\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nils Adermann", + "email": "naderman@naderman.de", + "homepage": "http://www.naderman.de" + }, + { + "name": "Jordi Boggiano", + "email": "j.boggiano@seld.be", + "homepage": "http://seld.be" + }, + { + "name": "Rob Bast", + "email": "rob.bast@gmail.com", + "homepage": "http://robbast.nl" + } + ], + "description": "SPDX licenses list and validation library.", + "keywords": [ + "license", + "spdx", + "validator" + ], + "funding": [ + { + "url": "https://packagist.com", + "type": "custom" + }, + { + "url": "https://github.com/composer", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/composer/composer", + "type": "tidelift" + } + ], + "time": "2020-07-15T15:35:07+00:00" + }, + { + "name": "composer/xdebug-handler", + "version": "1.4.2", + "source": { + "type": "git", + "url": "https://github.com/composer/xdebug-handler.git", + "reference": "fa2aaf99e2087f013a14f7432c1cd2dd7d8f1f51" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/fa2aaf99e2087f013a14f7432c1cd2dd7d8f1f51", + "reference": "fa2aaf99e2087f013a14f7432c1cd2dd7d8f1f51", + "shasum": "" + }, + "require": { + "php": "^5.3.2 || ^7.0 || ^8.0", + "psr/log": "^1.0" + }, + "require-dev": { + "phpunit/phpunit": "^4.8.35 || ^5.7 || 6.5 - 8" + }, + "type": "library", + "autoload": { + "psr-4": { + "Composer\\XdebugHandler\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "John Stevenson", + "email": "john-stevenson@blueyonder.co.uk" + } + ], + "description": "Restarts a process without Xdebug.", + "keywords": [ + "Xdebug", + "performance" + ], + "funding": [ + { + "url": "https://packagist.com", + "type": "custom" + }, + { + "url": "https://github.com/composer", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/composer/composer", + "type": "tidelift" + } + ], + "time": "2020-06-04T11:16:35+00:00" + }, { "name": "doctrine/instantiator", "version": "1.3.1", @@ -5350,20 +5629,6 @@ "constructor", "instantiate" ], - "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": "2020-05-29T17:27:14+00:00" }, { @@ -5707,6 +5972,72 @@ ], "time": "2020-07-09T08:09:16+00:00" }, + { + "name": "justinrainbow/json-schema", + "version": "5.2.10", + "source": { + "type": "git", + "url": "https://github.com/justinrainbow/json-schema.git", + "reference": "2ba9c8c862ecd5510ed16c6340aa9f6eadb4f31b" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/justinrainbow/json-schema/zipball/2ba9c8c862ecd5510ed16c6340aa9f6eadb4f31b", + "reference": "2ba9c8c862ecd5510ed16c6340aa9f6eadb4f31b", + "shasum": "" + }, + "require": { + "php": ">=5.3.3" + }, + "require-dev": { + "friendsofphp/php-cs-fixer": "~2.2.20||~2.15.1", + "json-schema/json-schema-test-suite": "1.2.0", + "phpunit/phpunit": "^4.8.35" + }, + "bin": [ + "bin/validate-json" + ], + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "5.0.x-dev" + } + }, + "autoload": { + "psr-4": { + "JsonSchema\\": "src/JsonSchema/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Bruno Prieto Reis", + "email": "bruno.p.reis@gmail.com" + }, + { + "name": "Justin Rainbow", + "email": "justin.rainbow@gmail.com" + }, + { + "name": "Igor Wiedler", + "email": "igor@wiedler.ch" + }, + { + "name": "Robert Schönthal", + "email": "seroscho@googlemail.com" + } + ], + "description": "A library to validate a json schema.", + "homepage": "https://github.com/justinrainbow/json-schema", + "keywords": [ + "json", + "schema" + ], + "time": "2020-05-27T16:41:55+00:00" + }, { "name": "mockery/mockery", "version": "1.3.2", @@ -5888,11 +6219,90 @@ "php", "symfony" ], + "time": "2020-04-04T19:56:08+00:00" + }, + { + "name": "nunomaduro/larastan", + "version": "v0.6.2", + "source": { + "type": "git", + "url": "https://github.com/nunomaduro/larastan.git", + "reference": "fd0ab4e585db15618ab6e78b368be456aa8c86ad" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/nunomaduro/larastan/zipball/fd0ab4e585db15618ab6e78b368be456aa8c86ad", + "reference": "fd0ab4e585db15618ab6e78b368be456aa8c86ad", + "shasum": "" + }, + "require": { + "composer/composer": "^1.0 || ^2.0", + "ext-json": "*", + "illuminate/console": "^6.0 || ^7.0 || ^8.0", + "illuminate/container": "^6.0 || ^7.0 || ^8.0", + "illuminate/contracts": "^6.0 || ^7.0 || ^8.0", + "illuminate/database": "^6.0 || ^7.0 || ^8.0", + "illuminate/http": "^6.0 || ^7.0 || ^8.0", + "illuminate/pipeline": "^6.0 || ^7.0 || ^8.0", + "illuminate/support": "^6.0 || ^7.0 || ^8.0", + "mockery/mockery": "^0.9 || ^1.0", + "php": "^7.2", + "phpstan/phpstan": "^0.12.34", + "symfony/process": "^4.3 || ^5.0" + }, + "require-dev": { + "orchestra/testbench": "^4.0 || ^5.0", + "phpunit/phpunit": "^7.3 || ^8.2" + }, + "suggest": { + "orchestra/testbench": "^4.0 || ^5.0" + }, + "type": "phpstan-extension", + "extra": { + "branch-alias": { + "dev-master": "0.6-dev" + }, + "phpstan": { + "includes": [ + "extension.neon" + ] + } + }, + "autoload": { + "psr-4": { + "NunoMaduro\\Larastan\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nuno Maduro", + "email": "enunomaduro@gmail.com" + } + ], + "description": "Larastan - Discover bugs in your code without running it. A phpstan/phpstan wrapper for Laravel", + "keywords": [ + "PHPStan", + "code analyse", + "code analysis", + "larastan", + "laravel", + "package", + "php", + "static analysis" + ], "funding": [ { "url": "https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=66BYDWAT92N6L", "type": "custom" }, + { + "url": "https://github.com/canvural", + "type": "github" + }, { "url": "https://github.com/nunomaduro", "type": "github" @@ -5902,7 +6312,7 @@ "type": "patreon" } ], - "time": "2020-04-04T19:56:08+00:00" + "time": "2020-07-30T19:33:12+00:00" }, { "name": "phar-io/manifest", @@ -6217,6 +6627,62 @@ ], "time": "2020-03-05T15:02:03+00:00" }, + { + "name": "phpstan/phpstan", + "version": "0.12.34", + "source": { + "type": "git", + "url": "https://github.com/phpstan/phpstan.git", + "reference": "ad75388d71fb0b4a954f71a852fd989915a51cb7" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/phpstan/phpstan/zipball/ad75388d71fb0b4a954f71a852fd989915a51cb7", + "reference": "ad75388d71fb0b4a954f71a852fd989915a51cb7", + "shasum": "" + }, + "require": { + "php": "^7.1|^8.0" + }, + "conflict": { + "phpstan/phpstan-shim": "*" + }, + "bin": [ + "phpstan", + "phpstan.phar" + ], + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "0.12-dev" + } + }, + "autoload": { + "files": [ + "bootstrap.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "PHPStan - PHP Static Analysis Tool", + "funding": [ + { + "url": "https://github.com/ondrejmirtes", + "type": "github" + }, + { + "url": "https://www.patreon.com/phpstan", + "type": "patreon" + }, + { + "url": "https://tidelift.com/funding/github/packagist/phpstan/phpstan", + "type": "tidelift" + } + ], + "time": "2020-07-30T15:31:10+00:00" + }, { "name": "phpunit/php-code-coverage", "version": "7.0.10", @@ -6629,12 +7095,6 @@ "highlight.php", "syntax" ], - "funding": [ - { - "url": "https://github.com/allejo", - "type": "github" - } - ], "time": "2020-03-02T05:59:21+00:00" }, { @@ -7252,6 +7712,173 @@ "homepage": "https://github.com/sebastianbergmann/version", "time": "2016-10-03T07:35:21+00:00" }, + { + "name": "seld/jsonlint", + "version": "1.8.0", + "source": { + "type": "git", + "url": "https://github.com/Seldaek/jsonlint.git", + "reference": "ff2aa5420bfbc296cf6a0bc785fa5b35736de7c1" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/Seldaek/jsonlint/zipball/ff2aa5420bfbc296cf6a0bc785fa5b35736de7c1", + "reference": "ff2aa5420bfbc296cf6a0bc785fa5b35736de7c1", + "shasum": "" + }, + "require": { + "php": "^5.3 || ^7.0 || ^8.0" + }, + "require-dev": { + "phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.0" + }, + "bin": [ + "bin/jsonlint" + ], + "type": "library", + "autoload": { + "psr-4": { + "Seld\\JsonLint\\": "src/Seld/JsonLint/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Jordi Boggiano", + "email": "j.boggiano@seld.be", + "homepage": "http://seld.be" + } + ], + "description": "JSON Linter", + "keywords": [ + "json", + "linter", + "parser", + "validator" + ], + "funding": [ + { + "url": "https://github.com/Seldaek", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/seld/jsonlint", + "type": "tidelift" + } + ], + "time": "2020-04-30T19:05:18+00:00" + }, + { + "name": "seld/phar-utils", + "version": "1.1.1", + "source": { + "type": "git", + "url": "https://github.com/Seldaek/phar-utils.git", + "reference": "8674b1d84ffb47cc59a101f5d5a3b61e87d23796" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/Seldaek/phar-utils/zipball/8674b1d84ffb47cc59a101f5d5a3b61e87d23796", + "reference": "8674b1d84ffb47cc59a101f5d5a3b61e87d23796", + "shasum": "" + }, + "require": { + "php": ">=5.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.x-dev" + } + }, + "autoload": { + "psr-4": { + "Seld\\PharUtils\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Jordi Boggiano", + "email": "j.boggiano@seld.be" + } + ], + "description": "PHAR file format utilities, for when PHP phars you up", + "keywords": [ + "phar" + ], + "time": "2020-07-07T18:42:57+00:00" + }, + { + "name": "symfony/filesystem", + "version": "v5.1.3", + "source": { + "type": "git", + "url": "https://github.com/symfony/filesystem.git", + "reference": "6e4320f06d5f2cce0d96530162491f4465179157" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/filesystem/zipball/6e4320f06d5f2cce0d96530162491f4465179157", + "reference": "6e4320f06d5f2cce0d96530162491f4465179157", + "shasum": "" + }, + "require": { + "php": ">=7.2.5", + "symfony/polyfill-ctype": "~1.8" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "5.1-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Filesystem\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Filesystem Component", + "homepage": "https://symfony.com", + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2020-05-30T20:35:19+00:00" + }, { "name": "theseer/tokenizer", "version": "1.1.3", diff --git a/conf/site/config/speedtest.php b/conf/site/config/speedtest.php index c93d2621..c9260593 100644 --- a/conf/site/config/speedtest.php +++ b/conf/site/config/speedtest.php @@ -7,7 +7,7 @@ return [ |-------------------------------------------------------------------------- */ - 'version' => '1.7.16', + 'version' => '1.7.17', /* |-------------------------------------------------------------------------- @@ -15,7 +15,7 @@ return [ |-------------------------------------------------------------------------- */ - 'install' => 'docker', + 'install' => 'manual', /* |-------------------------------------------------------------------------- @@ -23,7 +23,7 @@ return [ |-------------------------------------------------------------------------- */ - 'home' => 'HOME=/config', + 'home' => 'HOME=' . base_path() . DIRECTORY_SEPARATOR, /* |-------------------------------------------------------------------------- diff --git a/conf/site/package-lock.json b/conf/site/package-lock.json index b35f0172..e51f5a0a 100644 --- a/conf/site/package-lock.json +++ b/conf/site/package-lock.json @@ -2317,9 +2317,9 @@ "dev": true }, "bootstrap": { - "version": "4.5.0", - "resolved": "https://registry.npmjs.org/bootstrap/-/bootstrap-4.5.0.tgz", - "integrity": "sha512-Z93QoXvodoVslA+PWNdk23Hze4RBYIkpb5h8I2HY2Tu2h7A0LpAgLcyrhrSUyo2/Oxm2l1fRZPs1e5hnxnliXA==", + "version": "4.5.2", + "resolved": "https://registry.npmjs.org/bootstrap/-/bootstrap-4.5.2.tgz", + "integrity": "sha512-vlGn0bcySYl/iV+BGA544JkkZP5LB3jsmkeKLFQakCOwCM3AOk7VkldBz4jrzSe+Z0Ezn99NVXa1o45cQY4R6A==", "dev": true }, "brace-expansion": { @@ -8956,14 +8956,14 @@ } }, "sass-loader": { - "version": "9.0.2", - "resolved": "https://registry.npmjs.org/sass-loader/-/sass-loader-9.0.2.tgz", - "integrity": "sha512-nphcum3jNI442njnrZ5wJgSNX5lfEOHOKHCLf+PrTIaleploKqAMUuT9CVKjf+lyi6c2MCGPHh1vb9nGsjnZJA==", + "version": "9.0.3", + "resolved": "https://registry.npmjs.org/sass-loader/-/sass-loader-9.0.3.tgz", + "integrity": "sha512-fOwsP98ac1VMme+V3+o0HaaMHp8Q/C9P+MUazLFVi3Jl7ORGHQXL1XeRZt3zLSGZQQPC8xE42Y2WptItvGjDQg==", "dev": true, "requires": { - "klona": "^1.1.1", + "klona": "^1.1.2", "loader-utils": "^2.0.0", - "neo-async": "^2.6.1", + "neo-async": "^2.6.2", "schema-utils": "^2.7.0", "semver": "^7.3.2" }, @@ -8991,6 +8991,12 @@ "json5": "^2.1.2" } }, + "neo-async": { + "version": "2.6.2", + "resolved": "https://registry.npmjs.org/neo-async/-/neo-async-2.6.2.tgz", + "integrity": "sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw==", + "dev": true + }, "schema-utils": { "version": "2.7.0", "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-2.7.0.tgz", diff --git a/conf/site/package.json b/conf/site/package.json index 4df96526..7b15c488 100644 --- a/conf/site/package.json +++ b/conf/site/package.json @@ -12,7 +12,7 @@ "devDependencies": { "@babel/preset-react": "^7.10.4", "axios": "^0.19", - "bootstrap": "^4.5.0", + "bootstrap": "^4.5.2", "cross-env": "^7.0", "jquery": "^3.5", "laravel-mix": "^5.0.1", @@ -22,14 +22,14 @@ "react-dom": "^16.2.0", "resolve-url-loader": "^3.1.0", "sass": "^1.26.10", - "sass-loader": "^9.0.2" + "sass-loader": "^9.0.3" }, "dependencies": { "@babel/plugin-proposal-class-properties": "^7.10.4", "chart.js": "^2.9.3", "csv-file-validator": "^1.8.0", "react-bootstrap": "^1.3.0", - "react-chartjs-2": "^2.9.0", + "react-chartjs-2": "^2.10.0", "react-router": "^5.2.0", "react-router-dom": "^5.2.0", "react-toastify": "^6.0.8" diff --git a/conf/site/phpstan.neon b/conf/site/phpstan.neon new file mode 100644 index 00000000..0b8fb0be --- /dev/null +++ b/conf/site/phpstan.neon @@ -0,0 +1,18 @@ +includes: + - ./vendor/nunomaduro/larastan/extension.neon + +parameters: + + paths: + - app + + # The level 8 is the highest level + level: 5 + + ignoreErrors: + - '#Unsafe usage of new static#' + + excludes_analyse: + - ./*/*/FileToBeExcluded.php + + checkMissingIterableValueType: false