Closed viktorcsimma closed 1 month ago
app/Policies/RoomPolicy.php (1)
Line range hint `14-19`: **LGTM! But verify the definition and usage of the `TENANT` role.** The code changes to include the `TENANT` role in the `viewAny` method are approved. However, ensure that the `TENANT` role is correctly defined and used elsewhere in the codebase.Verification successful
--- **The `TENANT` role is correctly defined and extensively used throughout the codebase.** The code changes to include the `TENANT` role in the `viewAny` method are sound and consistent with the existing usage of the `TENANT` role. - `app/Models/Role.php`: Definition of the `TENANT` role. - `tests/Unit/RoleTest.php`: Usage in unit tests. - `resources/views/auth/register.blade.php`: Usage in views. - `database/seeders/UsersTableSeeder.php`: Usage in seeders. - `app/Policies/RoomPolicy.php`: Usage in policies. - `app/Providers/AuthServiceProvider.php`: Usage in providers. - `app/Models/User.php`: Usage in models. - `app/Http/Controllers/Auth/RegisterController.php`: Usage in controllers. - `app/Http/Middleware/EnsureVerified.php`: Usage in middleware.Scripts executed
The following scripts were executed for the analysis: Script: ```shell #!/bin/bash # Description: Verify the definition and usage of the `TENANT` role. # Test: Search for the definition of the `TENANT` role. Expect: Definition of the `TENANT` role. rg --type php 'const TENANT' -A 5 # Test: Search for the usage of the `TENANT` role. Expect: Usage of the `TENANT` role. rg --type php 'Role::TENANT' -A 5 ``` Length of output: 15625
I don't know if the collegists can see tenants now, but I'm not sure if the people want that anyone in the building can see where do they live. Thoughts?
As far as I can see, neither collegists see tenants nor vice versa.
Actually, it's a wish of some former collegists who want to interact with people inside. Maybe we could tie this to the alumni role. WDYT?
As far as I can see, neither collegists see tenants nor vice versa.
Then what's the point of this issue? btw, I just wanted to raise my concerns, I don't really care or want to make a statement. Ask the student council what makes sense.
The code itself is fine, I'll approve it
It's been voted down; I close this. Probably we should solve these user requests individually.
As in the title. Based on a user request.