From bf060e880c9ee175632b82c60fd5a1121de2300d Mon Sep 17 00:00:00 2001 From: spektra2147 Date: Thu, 9 Nov 2023 20:38:53 +0300 Subject: [PATCH 01/25] upgrade laravel -10 --- .gitignore | 1 - README.md | 4 +- composer.json | 29 ++-- docs/en/01.prologue/02.change-log.md | 22 +-- docs/en/02.getting-started/02.introduction.md | 2 +- docs/en/02.getting-started/03.installation.md | 2 +- .../en/02.getting-started/04.configuration.md | 6 +- docs/en/03.reference/02.hints.md | 10 +- docs/en/03.the-basics/08.contracts.md | 2 +- docs/en/05.core-concepts/04.image.md | 2 +- resources/config/distribution.php | 4 +- resources/config/settings/sections.php | 1 + resources/config/settings/settings.php | 8 + resources/lang/de/locale.php | 3 + resources/lang/en/setting.php | 5 + resources/lang/tr/setting.php | 4 + .../resources/views/partials/navigation.twig | 2 +- .../views/form/partials/translations.twig | 2 +- resources/views/notifications/email.twig | 4 +- resources/views/partials/constants.twig | 4 +- src/Addon/Addon.php | 21 ++- src/Addon/AddonManager.php | 43 ++++- src/Addon/AddonPaths.php | 2 +- src/Addon/Console/AddonDisable.php | 47 ++++++ src/Addon/Console/AddonPublish.php | 6 +- src/Addon/Console/Command/ScaffoldTheme.php | 2 +- .../Console/Command/WriteAddonButtonLang.php | 2 +- src/Addon/Console/Command/WriteAddonClass.php | 2 +- .../Console/Command/WriteAddonComposer.php | 2 +- .../Console/Command/WriteAddonFeatureTest.php | 2 +- .../Console/Command/WriteAddonFieldLang.php | 2 +- .../Console/Command/WriteAddonGitIgnore.php | 2 +- src/Addon/Console/Command/WriteAddonLang.php | 2 +- .../Console/Command/WriteAddonPackage.php | 2 +- .../Command/WriteAddonPermissionLang.php | 2 +- .../Console/Command/WriteAddonPermissions.php | 2 +- .../Console/Command/WriteAddonPhpUnit.php | 2 +- .../Console/Command/WriteAddonSectionLang.php | 2 +- .../Command/WriteAddonServiceProvider.php | 2 +- .../Console/Command/WriteAddonStreamLang.php | 2 +- .../Console/Command/WriteAddonTestCase.php | 2 +- .../Console/Command/WriteAddonWebpack.php | 2 +- .../Console/Command/WriteThemePackage.php | 2 +- .../Console/Command/WriteThemeWebpack.php | 2 +- src/Addon/Console/MakeAddon.php | 40 ++--- .../Extension/Command/InstallExtension.php | 2 +- src/Addon/Extension/ExtensionManager.php | 10 +- src/Addon/FieldType/FieldTypeQuery.php | 12 +- src/Addon/Module/Command/InstallModule.php | 2 +- src/Addon/Module/ModuleManager.php | 10 +- src/Application/Application.php | 10 +- src/Application/ApplicationManager.php | 2 +- .../Command/InitializeApplication.php | 5 +- .../Command/ReadEnvironmentFile.php | 2 +- .../Command/WriteEnvironmentFile.php | 2 +- src/Application/Console/AppPublish.php | 4 +- src/Application/Console/StreamsPublish.php | 6 +- src/Artisan/ArtisanServiceProvider.php | 1 + src/Asset/Asset.php | 11 ++ src/Asset/Filter/RubySassFilter.php | 2 +- src/Asset/Filter/RubyScssFilter.php | 2 +- src/Asset/Filter/SassFilter.php | 2 +- src/Asset/Filter/ScssFilter.php | 2 +- src/Assignment/AssignmentObserver.php | 16 +- .../Table/AssignmentTableBuilder.php | 4 +- src/Console/Application.php | 2 +- src/Console/Kernel.php | 19 +++ .../Console/Command/ConfigureCreator.php | 2 +- .../Console/Command/ConfigureMigrator.php | 2 +- .../Console/Command/MigrateStreams.php | 4 +- .../Migration/Console/MigrateCommand.php | 6 +- .../Migration/Console/MigrateMakeCommand.php | 2 +- .../Migration/Console/ResetCommand.php | 2 +- .../Migration/Console/RollbackCommand.php | 2 +- src/Database/Migration/MigrationCreator.php | 44 +----- .../Migration/MigrationServiceProvider.php | 13 -- src/Database/Migration/Migrator.php | 4 +- .../Console/Command/SetAddonSeederClass.php | 2 +- src/Database/Seeder/Console/SeedCommand.php | 2 +- src/Entry/EntryModel.php | 35 ++-- src/Entry/EntryObserver.php | 14 +- src/Entry/EntryTranslationsObserver.php | 2 +- src/Entry/EntryUtility.php | 6 +- src/Field/Command/ChangeFieldAssignments.php | 2 +- src/Field/Command/RenameFieldAssignments.php | 2 +- src/Field/Command/UpdateFieldAssignments.php | 2 +- src/Field/FieldObserver.php | 10 +- src/Field/Form/FieldFormBuilder.php | 2 +- src/Field/Form/FieldFormFields.php | 2 +- src/Http/CacheKernel.php | 11 +- src/Http/Controller/FormController.php | 13 +- src/Http/HttpCache.php | 2 +- .../Middleware/CheckForMaintenanceMode.php | 121 +++++++++++++- src/Http/Middleware/HttpCache.php | 12 +- src/Http/Store.php | 2 +- src/Image/Image.php | 14 +- src/Image/ImageMacros.php | 4 +- .../Console/Command/ConfigureDatabase.php | 2 +- .../Command/LoadApplicationInstallers.php | 2 +- .../Console/Command/LoadCoreInstallers.php | 2 +- .../Console/Command/SetDatabasePrefix.php | 11 +- src/Installer/Console/Install.php | 149 ++++++++++++------ src/Lang/Loader.php | 2 +- src/Lock/LockModel.php | 2 +- src/Model/EloquentModel.php | 24 ++- src/Model/EloquentObserver.php | 6 +- src/Model/EloquentQueryBuilder.php | 21 ++- src/Model/Traits/Translatable.php | 44 ++++-- src/Model/Traits/Versionable.php | 2 +- src/Routing/UrlGenerator.php | 5 +- .../Command/AppendEntityButtonLang.php | 2 +- .../Command/AppendEntityPermissionLang.php | 2 +- .../Command/AppendEntityPermissions.php | 2 +- .../Command/AppendEntitySectionLang.php | 2 +- .../Command/AppendEntityStreamLang.php | 2 +- .../Console/Command/WriteEntityCollection.php | 2 +- .../Console/Command/WriteEntityController.php | 2 +- .../Console/Command/WriteEntityCriteria.php | 2 +- .../Console/Command/WriteEntityFactory.php | 2 +- .../Command/WriteEntityFormBuilder.php | 2 +- .../Console/Command/WriteEntityModel.php | 2 +- .../Command/WriteEntityModelInterface.php | 2 +- .../Console/Command/WriteEntityObserver.php | 2 +- .../Console/Command/WriteEntityPresenter.php | 2 +- .../Console/Command/WriteEntityRepository.php | 2 +- .../WriteEntityRepositoryInterface.php | 2 +- .../Console/Command/WriteEntityRouter.php | 2 +- .../Console/Command/WriteEntityRoutes.php | 2 +- .../Console/Command/WriteEntitySeeder.php | 2 +- .../Command/WriteEntityTableBuilder.php | 2 +- .../Console/Command/WriteEntityTestCases.php | 2 +- .../Command/WriteEntityTreeBuilder.php | 2 +- src/Stream/Console/Make.php | 50 +++--- src/Stream/StreamModel.php | 4 +- src/Stream/StreamObserver.php | 16 +- src/StreamsCompilerProvider.php | 64 ++++---- src/StreamsPlugin.php | 32 ++-- src/StreamsServiceProvider.php | 57 +++---- .../Command/BuildControlPanel.php | 14 +- .../Component/Navigation/NavigationLink.php | 2 +- src/Ui/ControlPanel/ControlPanelBuilder.php | 2 +- src/Ui/Form/Command/BuildForm.php | 34 ++-- src/Ui/Form/Command/PostForm.php | 16 +- .../Form/Component/Field/FieldTranslator.php | 2 +- src/Ui/Form/FormBuilder.php | 22 +-- src/Ui/Form/FormRules.php | 2 +- src/Ui/Form/FormValidator.php | 4 +- src/Ui/Form/Multiple/Command/BuildForms.php | 2 +- src/Ui/Form/Multiple/Command/VersionForms.php | 2 +- src/Ui/Form/Multiple/MultipleFormBuilder.php | 14 +- src/Ui/Grid/Command/BuildGrid.php | 18 +-- src/Ui/Grid/Command/PostGrid.php | 2 +- src/Ui/Grid/GridBuilder.php | 12 +- src/Ui/Table/Command/BuildTable.php | 36 ++--- src/Ui/Table/Command/LoadTable.php | 2 +- src/Ui/Table/Command/PostTable.php | 4 +- .../Table/Multiple/MultipleTableBuilder.php | 12 +- src/Ui/Table/TableBuilder.php | 12 +- src/Ui/Tree/Command/BuildTree.php | 18 +-- src/Ui/Tree/Command/PostTree.php | 2 +- src/Ui/Tree/TreeBuilder.php | 18 +-- .../Command/ReadEnvironmentFileTest.php | 2 +- .../Command/ReloadEnvironmentFileTest.php | 8 +- .../Command/WriteEnvironmentFileTest.php | 8 +- tests/Unit/Asset/AssetTest.php | 4 +- 165 files changed, 941 insertions(+), 655 deletions(-) create mode 100644 src/Addon/Console/AddonDisable.php diff --git a/.gitignore b/.gitignore index 4499da806..0d1abf8d2 100644 --- a/.gitignore +++ b/.gitignore @@ -2,4 +2,3 @@ composer.lock /bin /vendor /coverage -/node_modules diff --git a/README.md b/README.md index 7a68b777c..ea7d830f0 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,9 @@ # Streams Platform -[![License](https://img.shields.io/badge/license-MIT-brightgreen.svg)](https://packagist.org/packages/anomaly/streams-platform) +[![License](https://img.shields.io/badge/license-MIT-brightgreen.svg)](https://packagist.org/packages/visiosoft/streams-platform) [![Build Status](https://scrutinizer-ci.com/g/anomalylabs/streams-platform/badges/build.png?b=master)](https://scrutinizer-ci.com/g/anomalylabs/streams-platform/build-status/master) [![Code Quality](http://img.shields.io/scrutinizer/g/anomalylabs/streams-platform.svg)](https://scrutinizer-ci.com/g/anomalylabs/streams-platform/) -[![Total Downloads](http://img.shields.io/packagist/dt/anomaly/streams.svg)](https://packagist.org/packages/anomaly/streams-platform) +[![Total Downloads](http://img.shields.io/packagist/dt/anomaly/streams.svg)](https://packagist.org/packages/visiosoft/streams-platform) [![Codacy Badge](https://api.codacy.com/project/badge/Grade/a0a603f4bb094044b9cc681b5a55506a)](https://www.codacy.com/app/RyanThompson/streams-platform?utm_source=github.com&utm_medium=referral&utm_content=anomalylabs/streams-platform&utm_campaign=Badge_Grade) [![SensioLabsInsight](https://insight.sensiolabs.com/projects/c07a737b-fd8f-43b1-a076-facbfb9ed2b0/small.png)](https://insight.sensiolabs.com/projects/c07a737b-fd8f-43b1-a076-facbfb9ed2b0) diff --git a/composer.json b/composer.json index 6233f5f59..6e055387d 100644 --- a/composer.json +++ b/composer.json @@ -1,5 +1,5 @@ { - "name": "anomaly/streams-platform", + "name": "visiosoft/streams-platform", "description": "A powerful, inclusive, modular PHP application engine built lovingly for Laravel.", "authors": [ { @@ -8,24 +8,27 @@ } ], "require": { - "laravel/framework": "^10.0", - "laravel/helpers": "^1.6", - "laravel/scout": "^10.0", - "doctrine/dbal": "^3.6", - "intervention/image": "^2.7.0", - "laravelcollective/html": "^6.3", + "laravel/framework": "^8.0", + "laravel/helpers": "^1.0", + "laravel/scout": "^8.2", + "doctrine/dbal": "^2.6", + "intervention/image": "^2.5.0", + "laravelcollective/html": "^6.1", "twig/twig": "^2.10", - "erusev/parsedown-extra": "^0.7|^0.8", + "barryvdh/laravel-debugbar": "^3.3", + "erusev/parsedown-extra": "^0.7.1", "linkorb/jsmin-php": "^1.0.0", "robclancy/presenter": "^1.3.0", - "nicmart/string-template": "^0.1.3", - "symfony/yaml": "^6.1", + "nicmart/string-template": "^0.1.0", + "symfony/yaml": "^4", "jenssegers/agent": "^2.6.0", - "barryvdh/laravel-httpcache": "^1.0", + "barryvdh/laravel-httpcache": "^0.3", "asm89/twig-cache-extension": "^1.3.0", - "vstelmakh/url-highlight": "^2.3", + "vstelmakh/url-highlight": "^2.2", "ezyang/htmlpurifier": "~4.0", - "tubalmartin/cssmin": "~4.0" + "tubalmartin/cssmin": "~4.0", + "fzaninotto/faker": "~1.4", + "scssphp/scssphp": "^1.11" }, "autoload": { "psr-4": { diff --git a/docs/en/01.prologue/02.change-log.md b/docs/en/01.prologue/02.change-log.md index 3a45cabd6..877946d17 100644 --- a/docs/en/01.prologue/02.change-log.md +++ b/docs/en/01.prologue/02.change-log.md @@ -28,30 +28,10 @@ Features that are deprecated will generally be removed in the next `minor` updat ## Releases -### [1.9.14] - 2022-12-14 -### Fixed -- Fixed issue with multi-site usage. - -### [1.9.13] - 2022-11-07 -### Added -- Added load relationships support to `$entry->toArray()` method. - -### [1.9.12] - 2022-07-29 -### Changed -- Removed `login` route from HTTP cache exlusion list. - -### [1.9.11] - 2022-07-29 -### Added -- Added a short-lived cookie to bypass HTTP cache after form submissions. - -### [1.9.10] - 2022-07-08 -### Fixed -- Fix issue with spaces in remote image URLs. - ### [1.9.8] - 2022-02-21 ### Fixed - Fix PHP 8 issue when filling `*` fields. - +- ### [1.9.7] - 2022-01-27 ### Fixed - Fix PHP 8 issue where filling `*` fields was removing a field upon symbol removal. diff --git a/docs/en/02.getting-started/02.introduction.md b/docs/en/02.getting-started/02.introduction.md index 57da02148..54988f08c 100644 --- a/docs/en/02.getting-started/02.introduction.md +++ b/docs/en/02.getting-started/02.introduction.md @@ -8,7 +8,7 @@ title: Introduction ## What is the Streams Platform? -The Streams Platform is a [Composer package](https://packagist.org/packages/anomaly/streams-platform) that serves as the foundation for PyroCMS. +The Streams Platform is a [Composer package](https://packagist.org/packages/visiosoft/streams-platform) that serves as the foundation for PyroCMS. Nearly every functionality in every addon for PyroCMS relies on the Streams Platform to do it's work. The Streams Platform is responsible for everything from [Table Builders](../ui/tables) to [Image](../core-principles/image) and [Asset](../core-principles/asset) pipelines to providing the actual addon layer itself. diff --git a/docs/en/02.getting-started/03.installation.md b/docs/en/02.getting-started/03.installation.md index 05a6c687c..49f7ef3cc 100644 --- a/docs/en/02.getting-started/03.installation.md +++ b/docs/en/02.getting-started/03.installation.md @@ -18,7 +18,7 @@ Before proceeding consider starting your project with a vanilla PyroCMS installa ### Download with Composer -First download the [package](https://packagist.org/packages/anomaly/streams-platform) by running `composer require anomaly/streams-platform`. +First download the [package](https://packagist.org/packages/visiosoft/streams-platform) by running `composer require visiosoft/streams-platform`. ### Register the service provider diff --git a/docs/en/02.getting-started/04.configuration.md b/docs/en/02.getting-started/04.configuration.md index fc15f3cf6..bb77e9d5e 100644 --- a/docs/en/02.getting-started/04.configuration.md +++ b/docs/en/02.getting-started/04.configuration.md @@ -8,7 +8,7 @@ title: Configuration ## Introduction -Streams configuration can be found in `vendor/anomaly/streams-platform/resources/config`. It is a good idea to look through the configuration files to get acquainted with what's available. +Streams configuration can be found in `vendor/visiosoft/streams-platform/resources/config`. It is a good idea to look through the configuration files to get acquainted with what's available. [Configuration Reference](../reference/configuration){.link} @@ -45,6 +45,6 @@ The [Settings](https://pyrocms.com/documentation/settings-module) and [Preferenc You can see what settings are bound to what configuration by reviewing the settings and preferences configuration found within the following files: ```bash -vendor/anomaly/streams-platform/resources/config/settings/settings.php -vendor/anomaly/streams-platform/resources/config/preferences/preferences.php +vendor/visiosoft/streams-platform/resources/config/settings/settings.php +vendor/visiosoft/streams-platform/resources/config/preferences/preferences.php ``` diff --git a/docs/en/03.reference/02.hints.md b/docs/en/03.reference/02.hints.md index 061dbe56a..7411c1257 100644 --- a/docs/en/03.reference/02.hints.md +++ b/docs/en/03.reference/02.hints.md @@ -65,7 +65,7 @@ The `storage::` path hint represents your application's storage directory `stora ### streams -The `streams::` path hint represents the `resources` directory for the Streams Platform `vendor/anomaly/streams-platform/resources/`. +The `streams::` path hint represents the `resources` directory for the Streams Platform `vendor/visiosoft/streams-platform/resources/`. ### module @@ -126,7 +126,7 @@ The `storage::` path hint represents your application's storage directory `stora ### streams -The `streams::` path hint represents the `resources` directory for the Streams Platform `vendor/anomaly/streams-platform/resources/`. +The `streams::` path hint represents the `resources` directory for the Streams Platform `vendor/visiosoft/streams-platform/resources/`. ## Config Hints @@ -147,7 +147,7 @@ Every addon has a config path hint for the addon's `config` directory `{addon_pa ### streams -The `streams::` path hint represents the `config` directory for the Streams Platform `vendor/anomaly/streams-platform/resources/config/`. +The `streams::` path hint represents the `config` directory for the Streams Platform `vendor/visiosoft/streams-platform/resources/config/`. ## Translator Hints @@ -176,7 +176,7 @@ The `theme::` path hint represents the `lang` directory for the `active` theme ` ### streams -The `streams::` path hint represents the `lang` directory for the Streams Platform `vendor/anomaly/streams-platform/resources/lang/`. +The `streams::` path hint represents the `lang` directory for the Streams Platform `vendor/visiosoft/streams-platform/resources/lang/`. ## View Hints @@ -205,7 +205,7 @@ The `theme::` path hint represents the `views` directory for the `active` theme ### streams -The `streams::` path hint represents the `views` directory for the Streams Platform `vendor/anomaly/streams-platform/resources/views/`. +The `streams::` path hint represents the `views` directory for the Streams Platform `vendor/visiosoft/streams-platform/resources/views/`. ### app diff --git a/docs/en/03.the-basics/08.contracts.md b/docs/en/03.the-basics/08.contracts.md index dab3f63db..5db165dec 100644 --- a/docs/en/03.the-basics/08.contracts.md +++ b/docs/en/03.the-basics/08.contracts.md @@ -12,7 +12,7 @@ Much of the Streams Platform and it's addons utilize the `interface` pattern. Th Contracts and implementations and resolving from the service container is used heavily within the Streams Platform in order to allow a very wide and low-level approach to extending core functionality. ```bash -/vendor/anomaly/streams-module/src/Entry/Contract/EntryInterface +/vendor/visiosoft/streams-module/src/Entry/Contract/EntryInterface ``` ### Loose Coupling diff --git a/docs/en/05.core-concepts/04.image.md b/docs/en/05.core-concepts/04.image.md index 89d736602..ba39f22a6 100644 --- a/docs/en/05.core-concepts/04.image.md +++ b/docs/en/05.core-concepts/04.image.md @@ -105,7 +105,7 @@ All paths are relative to your application's base path. * `asset`: public/app/{app_reference}/ * `storage`: storage/streams/{app_reference}/ * `download`: public/app/{app_reference}/assets/downloads/ -* `streams`: vendor/anomaly/streams-platform/resources/ +* `streams`: vendor/visiosoft/streams-platform/resources/ * `bower`: bin/bower_components/ * `theme`: {active_theme_path}/resources/ * `module`: {active_module_path}/resources/ diff --git a/resources/config/distribution.php b/resources/config/distribution.php index 08fec9249..2f89039f8 100644 --- a/resources/config/distribution.php +++ b/resources/config/distribution.php @@ -11,7 +11,7 @@ | */ - 'name' => 'Streams Platform', - 'description' => 'Streams is an abstracted modular platform for developing web applications.', + 'name' => 'PHP Classifieds Marketplace software', + 'description' => 'OpenClassify is modular and most advanced open source classified platform build with Laravel.Use it in real estate classifieds, auto, e-commerce and other ...', 'version' => 'v1.1', ]; diff --git a/resources/config/settings/sections.php b/resources/config/settings/sections.php index 3a47a0591..237afa272 100644 --- a/resources/config/settings/sections.php +++ b/resources/config/settings/sections.php @@ -50,6 +50,7 @@ 'mail_port', 'mail_username', 'mail_password', + 'mail_encrypt', ], ], 'cache' => [ diff --git a/resources/config/settings/settings.php b/resources/config/settings/settings.php index 5a23ea618..34bd1a5f9 100644 --- a/resources/config/settings/settings.php +++ b/resources/config/settings/settings.php @@ -266,6 +266,14 @@ 'type' => 'password', ], ], + 'mail_encrypt' => [ + 'env' => 'MAIL_ENCRYPTION', + 'bind' => 'mail.encryption', + 'type' => 'anomaly.field_type.text', + 'config' => [ + 'default_value' => 'ssl', + ], + ], 'http_cache' => [ 'env' => 'HTTP_CACHE', 'bind' => 'streams::httpcache.enabled', diff --git a/resources/lang/de/locale.php b/resources/lang/de/locale.php index cc42a179e..a47398804 100644 --- a/resources/lang/de/locale.php +++ b/resources/lang/de/locale.php @@ -52,6 +52,9 @@ 'cn' => [ 'name' => 'Chinesisch' ], + 'tr' => [ + 'name' => 'Türkisch' + ], 'tw' => [ 'name' => 'Twi' ], diff --git a/resources/lang/en/setting.php b/resources/lang/en/setting.php index bc18d8669..f280065b1 100644 --- a/resources/lang/en/setting.php +++ b/resources/lang/en/setting.php @@ -59,6 +59,7 @@ ], 'maintenance' => [ 'label' => 'Maintenance Mode', + 'warning' => 'Only admin users will be able to access the site.', 'instructions' => 'Use this option to the disable the public-facing part of the system.
This is useful when you want to take the site down for maintenance or development.', ], 'debug' => [ @@ -134,6 +135,10 @@ 'label' => 'SMTP Password', 'instructions' => 'Specify the SMTP password to use.', ], + 'mail_encrypt' => [ + 'label' => 'SMTP Encryption', + 'instructions' => 'Specify the SMTP encryption to use.', + ], 'http_cache' => [ 'label' => 'HTTP Cache', 'instructions' => 'Do you want to enable HTTP cache?', diff --git a/resources/lang/tr/setting.php b/resources/lang/tr/setting.php index b80a6c1f5..9a72bb5a4 100644 --- a/resources/lang/tr/setting.php +++ b/resources/lang/tr/setting.php @@ -134,6 +134,10 @@ 'label' => 'SMTP Şifresi', 'instructions' => 'Kullanılacak SMTP şifresini belirtin.', ], + 'mail_encrypt' => [ + 'label' => 'SMTP Şifreleme', + 'instructions' => 'Kullanılacak SMTP şifreleme yöntemini belirtin.', + ], 'http_cache' => [ 'label' => 'HTTP Önbelleği', 'instructions' => 'HTTP önbelleğini etkinleştirmek istiyor musunuz?', diff --git a/resources/stubs/addons/resources/views/partials/navigation.twig b/resources/stubs/addons/resources/views/partials/navigation.twig index e8d71adf8..4e70f5c1d 100644 --- a/resources/stubs/addons/resources/views/partials/navigation.twig +++ b/resources/stubs/addons/resources/views/partials/navigation.twig @@ -14,7 +14,7 @@ {{ structure() .bootstrap4() .listClass('nav navbar-nav') - .cache({'namespace': auth_user().id ~ ':' ~ config('app.locale')}) + .cache({'namespace': user().id ~ ':' ~ config('app.locale')}) .render()|raw }}