Overrides the models boot method.

@return void
976158
public static function boot()
    {
        parent::boot();

        self::creating(function ($invite) {
            if (!$invite->code) {
                $invite->code = Str::random(20);
            }
        });
    }
1115909
public function boot() {
    $this->publishConfig();
    $this->publishMigration();
    $this->publishAssets();
    $this->loadViewsFrom(__DIR__ . '/views', 'taxonomy');
    $this->loadTranslationsFrom(__DIR__ . '/lang', 'taxonomy');
  }
1246432
public function boot()
    {
        /*
         * Migrations
         */
        $this->publishes([
            __DIR__ . '/../database/factories' => database_path('factories/'),
        ], $this->package_tag . '-factories');
        $this->publishes([
            __DIR__ . '/../database/migrations' => database_path('migrations/'),
        ], $this->package_tag . '-migrations');
        $this->publishes([
            __DIR__ . '/../database/seeds' => database_path('seeds/'),
        ], $this->package_tag . '-seeds');

        /*
         * Commands
         */
        if ($this->app->runningInConsole()) {
            $this->commands([
                \CleaniqueCoders\Profile\Console\Commands\SeedProfileCommand::class,
            ]);
        }
    }
404829
public function boot()
    {
        if (config('modules.register.translations', true) === true) {
            $this->registerTranslation();
        }

        if ($this->isLoadFilesOnBoot()) {
            $this->registerFiles();
        }

        $this->fireEvent('boot');
    }
1094126
public function boot()
	{
		if ($this->booted)
		{
			return;
		}

		array_walk($this->serviceProviders, function($p)
		{
			$this->bootProvider($p);
		});

		$this->booted = true;
	}
708678
public function boot()
    {
        $this->loadViewsFrom(resource_path('admin-views'), 'admin');

        if (file_exists($routes = admin_path('routes.php'))) {
            $this->loadRoutesFrom($routes);
        }

        if ($this->app->runningInConsole()) {
            $this->publishes([
                __DIR__ . '/../resources/assets' => public_path('vendor'),
                __DIR__ . '/../resources/views' => resource_path('admin-views')
            ], 'laravel-admin-assets');

            $this->publishes([
                __DIR__ . '/../config' => config_path()
            ], 'laravel-admin-config');

            $this->publishes([
                __DIR__.'/../database' => database_path('migrations')
            ], 'laravel-admin-migrations');
        }
    }
450485
public function boot()
    {
        parent::boot();
        $this->bootTwig();
        $this->bootDatabase();
        $this->bootForm();
        $this->bootTranslation();
        $this->bootSwiftmailer();
        $this->registerControllers();
        $this->registerRoutes();
    }
1185358
protected static function boot(): void
    {
        parent::boot();

        /**
         * Attach to the 'creating' Model Event to provide record with user id which is now creating this record
         */
        static::creating(function($model) {

            if (auth()->user()) {
                $creatorId = auth()->id();
            } else {
                $creatorId = null;
            }

            $model->{'created_by'} = $creatorId;
        });
    }
854918
protected function boot(): void
    {
        // boot extensions
        foreach ($this->extensionManager->getExtensions() as $extension) {
            if ($extension->isActivated()) {
                $extension->boot();
            }
        }

        // boot app
        $this->dispatch(new RoutesWillBeLoaded($this->router));
        $this->dispatch(new RoutesHaveBeenLoaded($this->router));

        // send back responses
        try {
            $response = $this->router->getResponse();
            $response->send();
        } catch (RouteNotFoundException $exception) {
            throw new HttpNotFoundException();
        } catch (ResourceNotFoundException $exception) {
            throw new HttpNotFoundException();
        } catch (MethodNotAllowedException $exception) {
            throw new HttpMethodNotAllowedException();
        }
    }
1339262
protected static function boot()
    {
        parent::boot();

        static::creating(function (Model $model) {
            $model->{$model->getKeyName()} = Uuid::uuid1()->toString();
        });
    }
719773
public function boot()
  {
      $this->loadViewsFrom(__DIR__.'/resources/views', 'pagination');

      if ($this->app->runningInConsole()) {
          $this->publishes([
              __DIR__.'/resources/views' => $this->app->basePath('resources/views/vendor/pagination'),
          ], 'laravel-pagination');
      }
  }
590464
public function boot()
    {
        parent::boot();
        $this->loadViews();

        Event::listen([\Railken\Amethyst\Events\TemplateViewUpdated::class], function ($event) {
            Artisan::call('queue:restart');
        });
    }
846148
public function boot()
    {
        View::share('users', User::all());
        View::share('comments', Comment::all());
        View::share('comment', Comment::first());
    }
544457
public function boot()
    {
        $this['singular.config_loader']->loadConfigs();
        $this->autoload();

        if (!$this->booted) {
            $packs = $this['singular.packs']->keys();
            foreach ($packs as $packName) {
                $pack = $this['singular.packs'][$packName];
                $pack->boot($this);
                $pack->connect($this);
            }

            parent::boot();
        }
    }
900804
public function boot()
    {
        // routes
        if (!$this->app->routesAreCached()) {
            require __DIR__ . '/Http/routes.php';
        }

        // views
        $this->loadViewsFrom(__DIR__ . '/Views', 'visitlog');

        // publish our files over to main laravel app
        $this->publishes([
            __DIR__ . '/Config/visitlog.php' => config_path('visitlog.php'),
            __DIR__ . '/Migrations' => database_path('migrations')
        ]);
    }
767485
public function boot()
    {
        if ($this->booted) {
            return;
        }

        array_walk($this->loadedProviders, function ($p) {
            $this->bootProvider($p);
        });

        $this->booted = true;
    }
197676
protected static function boot()
    {
        parent::boot();

        self::$buildQueryScopeDefaults['columns'] = [
            'id',
            'user_id',
            'option_id',
        ];

        self::$buildQueryScopeDefaults['relations'] = [
            'option' => function (BelongsTo $optionQuery) {
                $optionQuery->select(['id', 'poll_id', 'answer']);
            },
        ];
    }