1178.accessing null values for non admin #1406
Draft
+45
−6
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
This is a draft update focusing on changes to Meters-related files, with no modifications to Groups or Units. The goal is to validate this solution approach. we dicide not remove any optional chain.
Evan Thomas - @ethomas5
Test
Searched and replaced relevant optional chaining in the src/client/app directory.
No compile-time or console errors were found during testing of the affected pages.
Reason could be The existing “logic protection” like Meters.js
Key Changes
File Adjustments: Modified Meters files to ensure data structures are correctly asserted as "Admin" where applicable.
Significance
Partly Addresses #1178
Type of change
Checklist
(Note what you have done by placing an "x" instead of the space in the [ ] so it becomes [x]. It is hoped you do all of them.)
Limitations
If this approach is approved, we will extend it to Groups and Units and submit a formal pull request.