mirror of https://github.com/kcal-app/kcal.git
Add phpstan support
This commit is contained in:
parent
d1c66924ea
commit
037d20fbb7
|
|
@ -7,20 +7,16 @@ use Illuminate\Foundation\Console\Kernel as ConsoleKernel;
|
||||||
|
|
||||||
class Kernel extends ConsoleKernel
|
class Kernel extends ConsoleKernel
|
||||||
{
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The Artisan commands provided by your application.
|
* @inheritdoc}
|
||||||
*
|
|
||||||
* @var array
|
|
||||||
*/
|
*/
|
||||||
protected $commands = [
|
protected $commands = [
|
||||||
//
|
//
|
||||||
];
|
];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Define the application's command schedule.
|
* @inheritdoc}
|
||||||
*
|
|
||||||
* @param \Illuminate\Console\Scheduling\Schedule $schedule
|
|
||||||
* @return void
|
|
||||||
*/
|
*/
|
||||||
protected function schedule(Schedule $schedule)
|
protected function schedule(Schedule $schedule)
|
||||||
{
|
{
|
||||||
|
|
@ -28,9 +24,7 @@ class Kernel extends ConsoleKernel
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Register the commands for the application.
|
* @inheritdoc}
|
||||||
*
|
|
||||||
* @return void
|
|
||||||
*/
|
*/
|
||||||
protected function commands()
|
protected function commands()
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -8,18 +8,14 @@ use Throwable;
|
||||||
class Handler extends ExceptionHandler
|
class Handler extends ExceptionHandler
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* A list of the exception types that are not reported.
|
* @inheritdoc}
|
||||||
*
|
|
||||||
* @var array
|
|
||||||
*/
|
*/
|
||||||
protected $dontReport = [
|
protected $dontReport = [
|
||||||
//
|
//
|
||||||
];
|
];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A list of the inputs that are never flashed for validation exceptions.
|
* @inheritdoc}
|
||||||
*
|
|
||||||
* @var array
|
|
||||||
*/
|
*/
|
||||||
protected $dontFlash = [
|
protected $dontFlash = [
|
||||||
'password',
|
'password',
|
||||||
|
|
@ -27,9 +23,7 @@ class Handler extends ExceptionHandler
|
||||||
];
|
];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Register the exception handling callbacks for the application.
|
* @inheritdoc}
|
||||||
*
|
|
||||||
* @return void
|
|
||||||
*/
|
*/
|
||||||
public function register()
|
public function register()
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -4,17 +4,15 @@ namespace App\Http\Controllers\Auth;
|
||||||
|
|
||||||
use App\Http\Controllers\Controller;
|
use App\Http\Controllers\Controller;
|
||||||
use App\Providers\RouteServiceProvider;
|
use App\Providers\RouteServiceProvider;
|
||||||
|
use Illuminate\Http\RedirectResponse;
|
||||||
use Illuminate\Http\Request;
|
use Illuminate\Http\Request;
|
||||||
|
|
||||||
class EmailVerificationNotificationController extends Controller
|
class EmailVerificationNotificationController extends Controller
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* Send a new email verification notification.
|
* Send a new email verification notification.
|
||||||
*
|
|
||||||
* @param \Illuminate\Http\Request $request
|
|
||||||
* @return \Illuminate\Http\Response
|
|
||||||
*/
|
*/
|
||||||
public function store(Request $request)
|
public function store(Request $request): RedirectResponse
|
||||||
{
|
{
|
||||||
if ($request->user()->hasVerifiedEmail()) {
|
if ($request->user()->hasVerifiedEmail()) {
|
||||||
return redirect()->intended(RouteServiceProvider::HOME);
|
return redirect()->intended(RouteServiceProvider::HOME);
|
||||||
|
|
|
||||||
|
|
@ -124,43 +124,38 @@ class JournalEntryController extends Controller
|
||||||
// TODO: Improve efficiency? Potential for lots of queries here...
|
// TODO: Improve efficiency? Potential for lots of queries here...
|
||||||
foreach ($ingredients as $ingredient) {
|
foreach ($ingredients as $ingredient) {
|
||||||
// Prepare entry values.
|
// Prepare entry values.
|
||||||
/**
|
$entry_key = "{$ingredient['date']}{$ingredient['meal']}";
|
||||||
* @var string $date
|
|
||||||
* @var string $meal
|
|
||||||
* @var float $amount
|
|
||||||
* @var string $unit
|
|
||||||
* @var int $id
|
|
||||||
* @var string $type
|
|
||||||
*/
|
|
||||||
extract($ingredient, EXTR_OVERWRITE);
|
|
||||||
$entry_key = "{$date}{$meal}";
|
|
||||||
$entries[$entry_key] = $entries[$entry_key] ?? JournalEntry::make([
|
$entries[$entry_key] = $entries[$entry_key] ?? JournalEntry::make([
|
||||||
'date' => $date,
|
'date' => $ingredient['date'],
|
||||||
'meal' => $meal,
|
'meal' => $ingredient['meal'],
|
||||||
])->user()->associate(Auth::user());
|
])->user()->associate(Auth::user());
|
||||||
|
|
||||||
// Calculate amounts based on ingredient type.
|
// Calculate amounts based on ingredient type.
|
||||||
if ($type == Food::class) {
|
if ($ingredient['type'] == Food::class) {
|
||||||
$item = Food::whereId($id)->first();
|
$item = Food::whereId($ingredient['id'])->first();
|
||||||
$nutrient_multiplier = Nutrients::calculateFoodNutrientMultiplier($item, Number::floatFromString($amount), $unit,);
|
$nutrient_multiplier = Nutrients::calculateFoodNutrientMultiplier(
|
||||||
|
$item,
|
||||||
|
Number::floatFromString($ingredient['amount']),
|
||||||
|
$ingredient['unit']
|
||||||
|
);
|
||||||
foreach (Nutrients::$all as $nutrient) {
|
foreach (Nutrients::$all as $nutrient) {
|
||||||
$entries[$entry_key]->{$nutrient} =+ $item->{$nutrient} * $nutrient_multiplier;
|
$entries[$entry_key]->{$nutrient} =+ $item->{$nutrient} * $nutrient_multiplier;
|
||||||
}
|
}
|
||||||
$entries[$entry_key]->foods->add($item);
|
$entries[$entry_key]->foods->add($item);
|
||||||
}
|
}
|
||||||
elseif ($type == Recipe::class) {
|
elseif ($ingredient['type'] == Recipe::class) {
|
||||||
$item = Recipe::whereId($id)->first();
|
$item = Recipe::whereId($ingredient['id'])->first();
|
||||||
foreach (Nutrients::$all as $nutrient) {
|
foreach (Nutrients::$all as $nutrient) {
|
||||||
$entries[$entry_key]->{$nutrient} += $item->{"{$nutrient}PerServing"}() * Number::floatFromString($amount);
|
$entries[$entry_key]->{$nutrient} += $item->{"{$nutrient}PerServing"}() * Number::floatFromString($ingredient['amount']);
|
||||||
}
|
}
|
||||||
$entries[$entry_key]->recipes->add($item);
|
$entries[$entry_key]->recipes->add($item);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
return back()->withInput()->withErrors("Invalid ingredient type {$type}.");
|
return back()->withInput()->withErrors("Invalid ingredient type {$ingredient['type']}.");
|
||||||
}
|
}
|
||||||
|
|
||||||
// Update summary
|
// Update summary
|
||||||
$entries[$entry_key]->summary .= (!empty($entries[$entry_key]->summary) ? ', ' : null) . "{$amount} {$unit} {$item->name}";
|
$entries[$entry_key]->summary .= (!empty($entries[$entry_key]->summary) ? ', ' : null) . "{$ingredient['amount']} {$ingredient['unit']} {$item->name}";
|
||||||
}
|
}
|
||||||
|
|
||||||
foreach ($entries as $entry) {
|
foreach ($entries as $entry) {
|
||||||
|
|
|
||||||
|
|
@ -251,14 +251,4 @@ class RecipeController extends Controller
|
||||||
return redirect()->route('recipes.show', $recipe);
|
return redirect()->route('recipes.show', $recipe);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Remove the specified resource from storage.
|
|
||||||
*
|
|
||||||
* @param \App\Models\Recipe $recipe
|
|
||||||
* @return \Illuminate\Http\Response
|
|
||||||
*/
|
|
||||||
public function destroy(Recipe $recipe)
|
|
||||||
{
|
|
||||||
//
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -7,11 +7,7 @@ use Illuminate\Foundation\Http\Kernel as HttpKernel;
|
||||||
class Kernel extends HttpKernel
|
class Kernel extends HttpKernel
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* The application's global HTTP middleware stack.
|
* {@inheritdoc}
|
||||||
*
|
|
||||||
* These middleware are run during every request to your application.
|
|
||||||
*
|
|
||||||
* @var array
|
|
||||||
*/
|
*/
|
||||||
protected $middleware = [
|
protected $middleware = [
|
||||||
// \App\Http\Middleware\TrustHosts::class,
|
// \App\Http\Middleware\TrustHosts::class,
|
||||||
|
|
@ -24,9 +20,7 @@ class Kernel extends HttpKernel
|
||||||
];
|
];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The application's route middleware groups.
|
* {@inheritdoc}
|
||||||
*
|
|
||||||
* @var array
|
|
||||||
*/
|
*/
|
||||||
protected $middlewareGroups = [
|
protected $middlewareGroups = [
|
||||||
'web' => [
|
'web' => [
|
||||||
|
|
@ -46,11 +40,7 @@ class Kernel extends HttpKernel
|
||||||
];
|
];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The application's route middleware.
|
* {@inheritdoc}
|
||||||
*
|
|
||||||
* These middleware may be assigned to groups or used individually.
|
|
||||||
*
|
|
||||||
* @var array
|
|
||||||
*/
|
*/
|
||||||
protected $routeMiddleware = [
|
protected $routeMiddleware = [
|
||||||
'auth' => \App\Http\Middleware\Authenticate::class,
|
'auth' => \App\Http\Middleware\Authenticate::class,
|
||||||
|
|
|
||||||
|
|
@ -7,15 +7,13 @@ use Illuminate\Auth\Middleware\Authenticate as Middleware;
|
||||||
class Authenticate extends Middleware
|
class Authenticate extends Middleware
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* Get the path the user should be redirected to when they are not authenticated.
|
* {@inheritdoc}
|
||||||
*
|
|
||||||
* @param \Illuminate\Http\Request $request
|
|
||||||
* @return string|null
|
|
||||||
*/
|
*/
|
||||||
protected function redirectTo($request)
|
protected function redirectTo($request)
|
||||||
{
|
{
|
||||||
if (! $request->expectsJson()) {
|
if (!$request->expectsJson()) {
|
||||||
return route('login');
|
return route('login');
|
||||||
}
|
}
|
||||||
|
return null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -7,9 +7,7 @@ use Illuminate\Cookie\Middleware\EncryptCookies as Middleware;
|
||||||
class EncryptCookies extends Middleware
|
class EncryptCookies extends Middleware
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* The names of the cookies that should not be encrypted.
|
* {@inheritdoc}
|
||||||
*
|
|
||||||
* @var array
|
|
||||||
*/
|
*/
|
||||||
protected $except = [
|
protected $except = [
|
||||||
//
|
//
|
||||||
|
|
|
||||||
|
|
@ -7,9 +7,7 @@ use Illuminate\Foundation\Http\Middleware\PreventRequestsDuringMaintenance as Mi
|
||||||
class PreventRequestsDuringMaintenance extends Middleware
|
class PreventRequestsDuringMaintenance extends Middleware
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* The URIs that should be reachable while maintenance mode is enabled.
|
* {@inheritdoc}
|
||||||
*
|
|
||||||
* @var array
|
|
||||||
*/
|
*/
|
||||||
protected $except = [
|
protected $except = [
|
||||||
//
|
//
|
||||||
|
|
|
||||||
|
|
@ -7,9 +7,7 @@ use Illuminate\Foundation\Http\Middleware\TrimStrings as Middleware;
|
||||||
class TrimStrings extends Middleware
|
class TrimStrings extends Middleware
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* The names of the attributes that should not be trimmed.
|
* {@inheritdoc}
|
||||||
*
|
|
||||||
* @var array
|
|
||||||
*/
|
*/
|
||||||
protected $except = [
|
protected $except = [
|
||||||
'password',
|
'password',
|
||||||
|
|
|
||||||
|
|
@ -7,9 +7,7 @@ use Illuminate\Http\Middleware\TrustHosts as Middleware;
|
||||||
class TrustHosts extends Middleware
|
class TrustHosts extends Middleware
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* Get the host patterns that should be trusted.
|
* {@inheritdoc}
|
||||||
*
|
|
||||||
* @return array
|
|
||||||
*/
|
*/
|
||||||
public function hosts()
|
public function hosts()
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -8,16 +8,12 @@ use Illuminate\Http\Request;
|
||||||
class TrustProxies extends Middleware
|
class TrustProxies extends Middleware
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* The trusted proxies for this application.
|
* {@inheritdoc}
|
||||||
*
|
|
||||||
* @var array|string|null
|
|
||||||
*/
|
*/
|
||||||
protected $proxies;
|
protected $proxies;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The headers that should be used to detect proxies.
|
* {@inheritdoc}
|
||||||
*
|
|
||||||
* @var int
|
|
||||||
*/
|
*/
|
||||||
protected $headers = Request::HEADER_X_FORWARDED_ALL;
|
protected $headers = Request::HEADER_X_FORWARDED_ALL;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -7,9 +7,7 @@ use Illuminate\Foundation\Http\Middleware\VerifyCsrfToken as Middleware;
|
||||||
class VerifyCsrfToken extends Middleware
|
class VerifyCsrfToken extends Middleware
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* The URIs that should be excluded from CSRF verification.
|
* {@inheritdoc}
|
||||||
*
|
|
||||||
* @var array
|
|
||||||
*/
|
*/
|
||||||
protected $except = [
|
protected $except = [
|
||||||
//
|
//
|
||||||
|
|
|
||||||
|
|
@ -66,7 +66,7 @@ use Spatie\Tags\HasTags;
|
||||||
* @method static \Illuminate\Database\Eloquent\Builder|Food withAnyTags($tags, ?string $type = null)
|
* @method static \Illuminate\Database\Eloquent\Builder|Food withAnyTags($tags, ?string $type = null)
|
||||||
* @method static \Illuminate\Database\Eloquent\Builder|Food withAnyTagsOfAnyType($tags)
|
* @method static \Illuminate\Database\Eloquent\Builder|Food withAnyTagsOfAnyType($tags)
|
||||||
*/
|
*/
|
||||||
class Food extends Model
|
final class Food extends Model
|
||||||
{
|
{
|
||||||
use HasFactory, HasTags, Ingredient, Journalable, Sluggable;
|
use HasFactory, HasTags, Ingredient, Journalable, Sluggable;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -23,8 +23,8 @@ use Illuminate\Database\Eloquent\Relations\BelongsTo;
|
||||||
* @property \Illuminate\Support\Carbon|null $created_at
|
* @property \Illuminate\Support\Carbon|null $created_at
|
||||||
* @property \Illuminate\Support\Carbon|null $updated_at
|
* @property \Illuminate\Support\Carbon|null $updated_at
|
||||||
* @property-read string $amount_formatted
|
* @property-read string $amount_formatted
|
||||||
* @property-read Model|\Eloquent $ingredient
|
* @property-read \App\Models\Food|\App\Models\Recipe $ingredient
|
||||||
* @property-read Model|\Eloquent $parent
|
* @property-read \App\Models\Recipe|\App\Models\JournalEntry $parent
|
||||||
* @method static \Illuminate\Database\Eloquent\Builder|IngredientAmount newModelQuery()
|
* @method static \Illuminate\Database\Eloquent\Builder|IngredientAmount newModelQuery()
|
||||||
* @method static \Illuminate\Database\Eloquent\Builder|IngredientAmount newQuery()
|
* @method static \Illuminate\Database\Eloquent\Builder|IngredientAmount newQuery()
|
||||||
* @method static \Illuminate\Database\Eloquent\Builder|IngredientAmount query()
|
* @method static \Illuminate\Database\Eloquent\Builder|IngredientAmount query()
|
||||||
|
|
@ -41,7 +41,7 @@ use Illuminate\Database\Eloquent\Relations\BelongsTo;
|
||||||
* @method static \Illuminate\Database\Eloquent\Builder|IngredientAmount whereWeight($value)
|
* @method static \Illuminate\Database\Eloquent\Builder|IngredientAmount whereWeight($value)
|
||||||
* @mixin \Eloquent
|
* @mixin \Eloquent
|
||||||
*/
|
*/
|
||||||
class IngredientAmount extends Model
|
final class IngredientAmount extends Model
|
||||||
{
|
{
|
||||||
use HasFactory;
|
use HasFactory;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -13,7 +13,7 @@ use Illuminate\Database\Eloquent\Relations\MorphToMany;
|
||||||
*
|
*
|
||||||
* @property int $id
|
* @property int $id
|
||||||
* @property int $user_id
|
* @property int $user_id
|
||||||
* @property \datetime $date
|
* @property \Illuminate\Support\Carbon $date
|
||||||
* @property string $summary
|
* @property string $summary
|
||||||
* @property float $calories
|
* @property float $calories
|
||||||
* @property float $fat
|
* @property float $fat
|
||||||
|
|
@ -49,7 +49,7 @@ use Illuminate\Database\Eloquent\Relations\MorphToMany;
|
||||||
* @property-read \Illuminate\Database\Eloquent\Collection|\App\Models\IngredientAmount[] $ingredients
|
* @property-read \Illuminate\Database\Eloquent\Collection|\App\Models\IngredientAmount[] $ingredients
|
||||||
* @property-read int|null $ingredients_count
|
* @property-read int|null $ingredients_count
|
||||||
*/
|
*/
|
||||||
class JournalEntry extends Model
|
final class JournalEntry extends Model
|
||||||
{
|
{
|
||||||
use HasFactory;
|
use HasFactory;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -53,7 +53,7 @@ use Spatie\Tags\HasTags;
|
||||||
* @method static \Illuminate\Database\Eloquent\Builder|Recipe withAnyTags($tags, ?string $type = null)
|
* @method static \Illuminate\Database\Eloquent\Builder|Recipe withAnyTags($tags, ?string $type = null)
|
||||||
* @method static \Illuminate\Database\Eloquent\Builder|Recipe withAnyTagsOfAnyType($tags)
|
* @method static \Illuminate\Database\Eloquent\Builder|Recipe withAnyTagsOfAnyType($tags)
|
||||||
*/
|
*/
|
||||||
class Recipe extends Model
|
final class Recipe extends Model
|
||||||
{
|
{
|
||||||
use HasFactory, HasIngredients, HasTags, Ingredient, Journalable, Sluggable;
|
use HasFactory, HasIngredients, HasTags, Ingredient, Journalable, Sluggable;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -27,7 +27,7 @@ use Illuminate\Database\Eloquent\Relations\BelongsTo;
|
||||||
* @method static \Illuminate\Database\Eloquent\Builder|RecipeStep whereUpdatedAt($value)
|
* @method static \Illuminate\Database\Eloquent\Builder|RecipeStep whereUpdatedAt($value)
|
||||||
* @mixin \Eloquent
|
* @mixin \Eloquent
|
||||||
*/
|
*/
|
||||||
class RecipeStep extends Model
|
final class RecipeStep extends Model
|
||||||
{
|
{
|
||||||
use HasFactory;
|
use HasFactory;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -33,7 +33,7 @@ use Illuminate\Notifications\Notifiable;
|
||||||
* @method static \Illuminate\Database\Eloquent\Builder|User whereUpdatedAt($value)
|
* @method static \Illuminate\Database\Eloquent\Builder|User whereUpdatedAt($value)
|
||||||
* @mixin \Eloquent
|
* @mixin \Eloquent
|
||||||
*/
|
*/
|
||||||
class User extends Authenticatable
|
final class User extends Authenticatable
|
||||||
{
|
{
|
||||||
use HasFactory, Notifiable;
|
use HasFactory, Notifiable;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -41,18 +41,21 @@ class Nutrients
|
||||||
$multiplier = match ($food->serving_unit) {
|
$multiplier = match ($food->serving_unit) {
|
||||||
'tbsp' => 1/3,
|
'tbsp' => 1/3,
|
||||||
'cup' => 1/48,
|
'cup' => 1/48,
|
||||||
|
default => throw new \DomainException(),
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
elseif ($fromUnit === 'tbsp') {
|
elseif ($fromUnit === 'tbsp') {
|
||||||
$multiplier = match ($food->serving_unit) {
|
$multiplier = match ($food->serving_unit) {
|
||||||
'tsp' => 3,
|
'tsp' => 3,
|
||||||
'cup' => 1/16,
|
'cup' => 1/16,
|
||||||
|
default => throw new \DomainException(),
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
elseif ($fromUnit === 'cup') {
|
elseif ($fromUnit === 'cup') {
|
||||||
$multiplier = match ($food->serving_unit) {
|
$multiplier = match ($food->serving_unit) {
|
||||||
'tsp' => 48,
|
'tsp' => 48,
|
||||||
'tbsp' => 16,
|
'tbsp' => 16,
|
||||||
|
default => throw new \DomainException(),
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
|
|
||||||
|
|
@ -24,6 +24,7 @@
|
||||||
"laravel/sail": "^0.0.5",
|
"laravel/sail": "^0.0.5",
|
||||||
"mockery/mockery": "^1.4.2",
|
"mockery/mockery": "^1.4.2",
|
||||||
"nunomaduro/collision": "^5.0",
|
"nunomaduro/collision": "^5.0",
|
||||||
|
"nunomaduro/larastan": "^0.6.13",
|
||||||
"phpunit/phpunit": "^9.3.3"
|
"phpunit/phpunit": "^9.3.3"
|
||||||
},
|
},
|
||||||
"config": {
|
"config": {
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
||||||
"This file is @generated automatically"
|
"This file is @generated automatically"
|
||||||
],
|
],
|
||||||
"content-hash": "346f8fdf213e965dba75a3adbcd0c247",
|
"content-hash": "7b4bf3adf3d57d7b218fd422cc1e50a9",
|
||||||
"packages": [
|
"packages": [
|
||||||
{
|
{
|
||||||
"name": "asm89/stack-cors",
|
"name": "asm89/stack-cors",
|
||||||
|
|
@ -7480,6 +7480,103 @@
|
||||||
],
|
],
|
||||||
"time": "2020-10-29T14:50:40+00:00"
|
"time": "2020-10-29T14:50:40+00:00"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "nunomaduro/larastan",
|
||||||
|
"version": "v0.6.13",
|
||||||
|
"source": {
|
||||||
|
"type": "git",
|
||||||
|
"url": "https://github.com/nunomaduro/larastan.git",
|
||||||
|
"reference": "7a047f7974e6e16d04ee038d86e2c5e6c59e9dfe"
|
||||||
|
},
|
||||||
|
"dist": {
|
||||||
|
"type": "zip",
|
||||||
|
"url": "https://api.github.com/repos/nunomaduro/larastan/zipball/7a047f7974e6e16d04ee038d86e2c5e6c59e9dfe",
|
||||||
|
"reference": "7a047f7974e6e16d04ee038d86e2c5e6c59e9dfe",
|
||||||
|
"shasum": ""
|
||||||
|
},
|
||||||
|
"require": {
|
||||||
|
"composer/composer": "^1.0 || ^2.0",
|
||||||
|
"ext-json": "*",
|
||||||
|
"illuminate/console": "^6.0 || ^7.0 || ^8.0 || ^9.0",
|
||||||
|
"illuminate/container": "^6.0 || ^7.0 || ^8.0 || ^9.0",
|
||||||
|
"illuminate/contracts": "^6.0 || ^7.0 || ^8.0 || ^9.0",
|
||||||
|
"illuminate/database": "^6.0 || ^7.0 || ^8.0 || ^9.0",
|
||||||
|
"illuminate/http": "^6.0 || ^7.0 || ^8.0 || ^9.0",
|
||||||
|
"illuminate/pipeline": "^6.0 || ^7.0 || ^8.0 || ^9.0",
|
||||||
|
"illuminate/support": "^6.0 || ^7.0 || ^8.0 || ^9.0",
|
||||||
|
"mockery/mockery": "^0.9 || ^1.0",
|
||||||
|
"php": "^7.2 || ^8.0",
|
||||||
|
"phpstan/phpstan": "^0.12.65",
|
||||||
|
"symfony/process": "^4.3 || ^5.0"
|
||||||
|
},
|
||||||
|
"require-dev": {
|
||||||
|
"orchestra/testbench": "^4.0 || ^5.0 || ^6.0 || ^7.0",
|
||||||
|
"phpunit/phpunit": "^7.3 || ^8.2 || ^9.3"
|
||||||
|
},
|
||||||
|
"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"
|
||||||
|
],
|
||||||
|
"support": {
|
||||||
|
"issues": "https://github.com/nunomaduro/larastan/issues",
|
||||||
|
"source": "https://github.com/nunomaduro/larastan/tree/v0.6.13"
|
||||||
|
},
|
||||||
|
"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"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"url": "https://www.patreon.com/nunomaduro",
|
||||||
|
"type": "patreon"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"time": "2021-01-22T12:51:26+00:00"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "phar-io/manifest",
|
"name": "phar-io/manifest",
|
||||||
"version": "2.0.1",
|
"version": "2.0.1",
|
||||||
|
|
@ -7816,6 +7913,66 @@
|
||||||
},
|
},
|
||||||
"time": "2020-12-19T10:15:11+00:00"
|
"time": "2020-12-19T10:15:11+00:00"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "phpstan/phpstan",
|
||||||
|
"version": "0.12.69",
|
||||||
|
"source": {
|
||||||
|
"type": "git",
|
||||||
|
"url": "https://github.com/phpstan/phpstan.git",
|
||||||
|
"reference": "8f436ea35241da33487fd0d38b4bc3e6dfe30ea8"
|
||||||
|
},
|
||||||
|
"dist": {
|
||||||
|
"type": "zip",
|
||||||
|
"url": "https://api.github.com/repos/phpstan/phpstan/zipball/8f436ea35241da33487fd0d38b4bc3e6dfe30ea8",
|
||||||
|
"reference": "8f436ea35241da33487fd0d38b4bc3e6dfe30ea8",
|
||||||
|
"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",
|
||||||
|
"support": {
|
||||||
|
"issues": "https://github.com/phpstan/phpstan/issues",
|
||||||
|
"source": "https://github.com/phpstan/phpstan/tree/0.12.69"
|
||||||
|
},
|
||||||
|
"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": "2021-01-24T14:55:37+00:00"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "phpunit/php-code-coverage",
|
"name": "phpunit/php-code-coverage",
|
||||||
"version": "9.2.5",
|
"version": "9.2.5",
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,8 @@
|
||||||
|
includes:
|
||||||
|
- ./vendor/nunomaduro/larastan/extension.neon
|
||||||
|
|
||||||
|
parameters:
|
||||||
|
paths:
|
||||||
|
- app
|
||||||
|
level: 6
|
||||||
|
checkMissingIterableValueType: false
|
||||||
Loading…
Reference in New Issue