ErrorException {#357 #severity: E_WARNING }
**/
public function startSession(): bool
{
if ($this->sessionState == self::SESSION_NOT_STARTED) {
$this->sessionState = session_start();
}
return $this->sessionState;
}
* @return callable
*/
protected function forwardsTo($method)
{
return fn (...$arguments) => static::$app
? $this->{$method}(...$arguments)
: false;
}
/**
* Determine if the error level is a deprecation.
**/
public function startSession(): bool
{
if ($this->sessionState == self::SESSION_NOT_STARTED) {
$this->sessionState = session_start();
}
return $this->sessionState;
}
{
if (!isset(self::$instance)) {
self::$instance = new self();
}
self::$instance->startSession();
return self::$instance;
}
Blade::directive('price', function (int|string|float $price) {
// TODO: check wtf with $price
return "<?php echo view('front.formatters.price', ['price' => $price]); ?>";
});
$session = Session::getInstance();
$defaultCitySlug = env('DEFAULT_CITY', 'Minsk');
$chosenCity = $_GET['city'] ?? (cookie('city')->getValue() ?? $session->city);
$currentCity = City::where('slug', $chosenCity)->first() ?? City::where('slug', $defaultCitySlug)->first();
if (static::isCallableWithAtSign($callback) || $defaultMethod) {
return static::callClass($container, $callback, $parameters, $defaultMethod);
}
return static::callBoundMethod($container, $callback, function () use ($container, $callback, $parameters) {
return $callback(...array_values(static::getMethodDependencies($container, $callback, $parameters)));
});
}
/**
* Call a string reference to a class using Class@method syntax.
* @param mixed ...$args
* @return mixed
*/
public static function unwrapIfClosure($value, ...$args)
{
return $value instanceof Closure ? $value(...$args) : $value;
}
/**
* Get the class name of the given parameter's type, if possible.
*
if ($container->hasMethodBinding($method)) {
return $container->callMethodBinding($method, $callback[0]);
}
return Util::unwrapIfClosure($default);
}
/**
* Normalize the given callback into a Class@method string.
*
if (static::isCallableWithAtSign($callback) || $defaultMethod) {
return static::callClass($container, $callback, $parameters, $defaultMethod);
}
return static::callBoundMethod($container, $callback, function () use ($container, $callback, $parameters) {
return $callback(...array_values(static::getMethodDependencies($container, $callback, $parameters)));
});
}
/**
$this->buildStack[] = $className;
$pushedToBuildStack = true;
}
$result = BoundMethod::call($this, $callback, $parameters, $defaultMethod);
if ($pushedToBuildStack) {
array_pop($this->buildStack);
}
protected function bootProvider(ServiceProvider $provider)
{
$provider->callBootingCallbacks();
if (method_exists($provider, 'boot')) {
$this->call([$provider, 'boot']);
}
$provider->callBootedCallbacks();
}
// for any listeners that need to do work after this initial booting gets
// finished. This is useful when ordering the boot-up processes we run.
$this->fireAppCallbacks($this->bootingCallbacks);
array_walk($this->serviceProviders, function ($p) {
$this->bootProvider($p);
});
$this->booted = true;
$this->fireAppCallbacks($this->bootedCallbacks);
// Once the application has booted we will also fire some "booted" callbacks
// for any listeners that need to do work after this initial booting gets
// finished. This is useful when ordering the boot-up processes we run.
$this->fireAppCallbacks($this->bootingCallbacks);
array_walk($this->serviceProviders, function ($p) {
$this->bootProvider($p);
});
$this->booted = true;
* @param \Illuminate\Contracts\Foundation\Application $app
* @return void
*/
public function bootstrap(Application $app)
{
$app->boot();
}
}
$this->hasBeenBootstrapped = true;
foreach ($bootstrappers as $bootstrapper) {
$this['events']->dispatch('bootstrapping: '.$bootstrapper, [$this]);
$this->make($bootstrapper)->bootstrap($this);
$this['events']->dispatch('bootstrapped: '.$bootstrapper, [$this]);
}
}
* @return void
*/
public function bootstrap()
{
if (! $this->app->hasBeenBootstrapped()) {
$this->app->bootstrapWith($this->bootstrappers());
}
}
/**
* Get the route dispatcher callback.
}
} else {
die('Domain is not allowed: ' .$domain);
}
parent::bootstrap();
}
}
{
$this->app->instance('request', $request);
Facade::clearResolvedInstance('request');
$this->bootstrap();
return (new Pipeline($this->app))
->send($request)
->through($this->app->shouldSkipMiddleware() ? [] : $this->middleware)
->then($this->dispatchToRouter());
$this->requestStartedAt = Carbon::now();
try {
$request->enableHttpMethodParameterOverride();
$response = $this->sendRequestThroughRouter($request);
} catch (Throwable $e) {
$this->reportException($e);
$response = $this->renderException($request, $e);
}
$app = require_once __DIR__.'/../bootstrap/app.php';
$kernel = $app->make(Kernel::class);
$response = $kernel->handle(
$request = Request::capture()
)->send();
$kernel->terminate($request, $response);
ErrorException
|
---|
ErrorException: session_start(): open(/home/avtoshina/www/avtoshina.site/storage/session/sess_3vcfb0836iujrg8ipa12fi2qsk, O_RDWR) failed: No space left on device (28) at /home/avtoshina/www/avtoshina.site/app/Services/Session.php:58 at Illuminate\Foundation\Bootstrap\HandleExceptions->handleError() (/home/avtoshina/www/avtoshina.site/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/HandleExceptions.php:255) at Illuminate\Foundation\Bootstrap\HandleExceptions->Illuminate\Foundation\Bootstrap\{closure}() at session_start() (/home/avtoshina/www/avtoshina.site/app/Services/Session.php:58) at App\Services\Session->startSession() (/home/avtoshina/www/avtoshina.site/app/Services/Session.php:43) at App\Services\Session::getInstance() (/home/avtoshina/www/avtoshina.site/app/Providers/FrontServiceProvider.php:39) at App\Providers\FrontServiceProvider->boot() (/home/avtoshina/www/avtoshina.site/vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php:36) at Illuminate\Container\BoundMethod::Illuminate\Container\{closure}() (/home/avtoshina/www/avtoshina.site/vendor/laravel/framework/src/Illuminate/Container/Util.php:41) at Illuminate\Container\Util::unwrapIfClosure() (/home/avtoshina/www/avtoshina.site/vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php:93) at Illuminate\Container\BoundMethod::callBoundMethod() (/home/avtoshina/www/avtoshina.site/vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php:35) at Illuminate\Container\BoundMethod::call() (/home/avtoshina/www/avtoshina.site/vendor/laravel/framework/src/Illuminate/Container/Container.php:662) at Illuminate\Container\Container->call() (/home/avtoshina/www/avtoshina.site/vendor/laravel/framework/src/Illuminate/Foundation/Application.php:1030) at Illuminate\Foundation\Application->bootProvider() (/home/avtoshina/www/avtoshina.site/vendor/laravel/framework/src/Illuminate/Foundation/Application.php:1011) at Illuminate\Foundation\Application->Illuminate\Foundation\{closure}() at array_walk() (/home/avtoshina/www/avtoshina.site/vendor/laravel/framework/src/Illuminate/Foundation/Application.php:1010) at Illuminate\Foundation\Application->boot() (/home/avtoshina/www/avtoshina.site/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/BootProviders.php:17) at Illuminate\Foundation\Bootstrap\BootProviders->bootstrap() (/home/avtoshina/www/avtoshina.site/vendor/laravel/framework/src/Illuminate/Foundation/Application.php:263) at Illuminate\Foundation\Application->bootstrapWith() (/home/avtoshina/www/avtoshina.site/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php:186) at Illuminate\Foundation\Http\Kernel->bootstrap() (/home/avtoshina/www/avtoshina.site/app/Http/Kernel.php:94) at App\Http\Kernel->bootstrap() (/home/avtoshina/www/avtoshina.site/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php:170) at Illuminate\Foundation\Http\Kernel->sendRequestThroughRouter() (/home/avtoshina/www/avtoshina.site/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php:144) at Illuminate\Foundation\Http\Kernel->handle() (/home/avtoshina/www/avtoshina.site/public/index.php:51) |