[PR #4554] [MERGED] Guest control: Cleaned methods involved in fetching/handling #6375

Closed
opened 2026-02-05 10:30:38 +03:00 by OVERLORD · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/BookStackApp/BookStack/pull/4554
Author: @ssddanbrown
Created: 9/16/2023
Status: Merged
Merged: 9/16/2023
Merged by: @ssddanbrown

Base: developmentHead: guest_user_cleanup


📝 Commits (2)

  • b90033a Guest control: Cleaned methods involved in fetching/handling
  • e16bdf4 Removed redundant null check

📊 Changes

30 files changed (+141 additions, -159 deletions)

View changed files

📝 app/Activity/Models/View.php (+1 -1)
📝 app/Activity/Tools/UserEntityWatchOptions.php (+1 -1)
📝 app/App/Providers/AuthServiceProvider.php (+7 -0)
📝 app/App/helpers.php (+2 -18)
📝 app/Entities/Queries/RecentlyViewed.php (+1 -1)
📝 app/Entities/Queries/TopFavourites.php (+1 -1)
📝 app/Http/Controller.php (+1 -1)
📝 app/Http/Middleware/ApiAuthenticate.php (+2 -2)
📝 app/Http/Middleware/Authenticate.php (+1 -1)
📝 app/Http/Middleware/PreventAuthenticatedResponseCaching.php (+1 -1)
📝 app/Settings/SettingController.php (+1 -1)
📝 app/Settings/SettingService.php (+2 -2)
📝 app/Translation/LanguageManager.php (+1 -1)
📝 app/Users/Controllers/UserSearchController.php (+1 -1)
📝 app/Users/Models/User.php (+11 -18)
📝 resources/views/books/show.blade.php (+1 -1)
📝 resources/views/chapters/show.blade.php (+1 -1)
resources/views/common/header-user-menu.blade.php (+47 -0)
📝 resources/views/common/header.blade.php (+7 -54)
📝 resources/views/errors/404.blade.php (+39 -39)

...and 10 more files

📄 Description

  • Moves guest user caching from User class to app container for simplicity.
  • Updates test to use simpler $this->users->guest() method for consistency.
  • Streamlined helpers to avoid function overlap for simplicity.
  • Extracted user profile dropdown while doing changes.

For #4448


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/BookStackApp/BookStack/pull/4554 **Author:** [@ssddanbrown](https://github.com/ssddanbrown) **Created:** 9/16/2023 **Status:** ✅ Merged **Merged:** 9/16/2023 **Merged by:** [@ssddanbrown](https://github.com/ssddanbrown) **Base:** `development` ← **Head:** `guest_user_cleanup` --- ### 📝 Commits (2) - [`b90033a`](https://github.com/BookStackApp/BookStack/commit/b90033a73032da8657f1bd3ec3687aa4426d8cc1) Guest control: Cleaned methods involved in fetching/handling - [`e16bdf4`](https://github.com/BookStackApp/BookStack/commit/e16bdf443ce68e6363ea40124d66eb15c05f2e8b) Removed redundant null check ### 📊 Changes **30 files changed** (+141 additions, -159 deletions) <details> <summary>View changed files</summary> 📝 `app/Activity/Models/View.php` (+1 -1) 📝 `app/Activity/Tools/UserEntityWatchOptions.php` (+1 -1) 📝 `app/App/Providers/AuthServiceProvider.php` (+7 -0) 📝 `app/App/helpers.php` (+2 -18) 📝 `app/Entities/Queries/RecentlyViewed.php` (+1 -1) 📝 `app/Entities/Queries/TopFavourites.php` (+1 -1) 📝 `app/Http/Controller.php` (+1 -1) 📝 `app/Http/Middleware/ApiAuthenticate.php` (+2 -2) 📝 `app/Http/Middleware/Authenticate.php` (+1 -1) 📝 `app/Http/Middleware/PreventAuthenticatedResponseCaching.php` (+1 -1) 📝 `app/Settings/SettingController.php` (+1 -1) 📝 `app/Settings/SettingService.php` (+2 -2) 📝 `app/Translation/LanguageManager.php` (+1 -1) 📝 `app/Users/Controllers/UserSearchController.php` (+1 -1) 📝 `app/Users/Models/User.php` (+11 -18) 📝 `resources/views/books/show.blade.php` (+1 -1) 📝 `resources/views/chapters/show.blade.php` (+1 -1) ➕ `resources/views/common/header-user-menu.blade.php` (+47 -0) 📝 `resources/views/common/header.blade.php` (+7 -54) 📝 `resources/views/errors/404.blade.php` (+39 -39) _...and 10 more files_ </details> ### 📄 Description - Moves guest user caching from User class to app container for simplicity. - Updates test to use simpler $this->users->guest() method for consistency. - Streamlined helpers to avoid function overlap for simplicity. - Extracted user profile dropdown while doing changes. For #4448 --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
OVERLORD added the pull-request label 2026-02-05 10:30:38 +03:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/BookStack#6375