[PR #2586] [CLOSED] Fixing default config lookup for bookshelves_view_type in BookshelfController #6025

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

📋 Pull Request Information

Original PR: https://github.com/BookStackApp/BookStack/pull/2586
Author: @philjak
Created: 2/24/2021
Status: Closed

Base: masterHead: bugfix_default_bookshelf_view_type


📝 Commits (2)

  • ada92cb Fixing default config lookup for bookshelves_view_type
  • c346050 Adjusting test

📊 Changes

2 files changed (+2 additions, -2 deletions)

View changed files

📝 app/Http/Controllers/BookshelfController.php (+1 -1)
📝 tests/User/UserProfileTest.php (+1 -1)

📄 Description

A wrong setting key (bookshelf_view_type) was used. So the configured default in .env was not used. This PR fixes this issue.

How to reproduce:

  • Set APP_VIEWS_BOOKSHELVES=list in .env File
  • Use a new user and open a random bookshelf (/shelves/{slug})

Expected: See books as list.

What actually happens: Default grid view is shown.


🔄 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/2586 **Author:** [@philjak](https://github.com/philjak) **Created:** 2/24/2021 **Status:** ❌ Closed **Base:** `master` ← **Head:** `bugfix_default_bookshelf_view_type` --- ### 📝 Commits (2) - [`ada92cb`](https://github.com/BookStackApp/BookStack/commit/ada92cbde39640c37c1a9076ed4ebd6980919267) Fixing default config lookup for bookshelves_view_type - [`c346050`](https://github.com/BookStackApp/BookStack/commit/c346050a4212f42dbd4c814ba00babadee168776) Adjusting test ### 📊 Changes **2 files changed** (+2 additions, -2 deletions) <details> <summary>View changed files</summary> 📝 `app/Http/Controllers/BookshelfController.php` (+1 -1) 📝 `tests/User/UserProfileTest.php` (+1 -1) </details> ### 📄 Description A wrong setting key (`bookshelf_view_type`) was used. So the configured default in `.env` was not used. This PR fixes this issue. How to reproduce: - Set `APP_VIEWS_BOOKSHELVES=list` in `.env` File - Use a new user and open a random bookshelf (/shelves/{slug}) Expected: See books as list. What actually happens: Default grid view is shown. --- <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:22:52 +03:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/BookStack#6025