Commit 017ab9c
fix(admin): address Copilot review feedback
- Escape the row class attribute: replace the inline ternary that
conditionally injected ` class="disabled"` with a computed
`$row_class` string echoed through esc_attr(). Resolves the
WordPress.Security.EscapeOutput risk Copilot flagged at line 204.
- wp_die() in render_page() now passes response code 403 + back_link
so automated clients and access logs reflect the authorization
failure correctly instead of falling back to a generic error.
Both changes are local to includes/Admin/SettingsPage.php. No behavior
change beyond the response code; the same denial still blocks the
render path when current_user_can( manage_options ) is false.
Refs Copilot review on PR #184.
Co-authored-by: webmyc <urbankidro@git.wordpress.org>1 parent 40cff59 commit 017ab9c
1 file changed
Lines changed: 10 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
157 | 157 | | |
158 | 158 | | |
159 | 159 | | |
160 | | - | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
161 | 168 | | |
162 | 169 | | |
163 | 170 | | |
| |||
201 | 208 | | |
202 | 209 | | |
203 | 210 | | |
204 | | - | |
| 211 | + | |
| 212 | + | |
205 | 213 | | |
206 | 214 | | |
207 | 215 | | |
| |||
0 commit comments