Use optional chaining instead of repeated access (S6582)
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -42,8 +42,7 @@ export const usePageAdminStore = defineStore("pageAdminStore", {
|
|||||||
setActivePageComputedByRoute(routeMatched) {
|
setActivePageComputedByRoute(routeMatched) {
|
||||||
if (
|
if (
|
||||||
routeMatched.length &&
|
routeMatched.length &&
|
||||||
routeMatched[routeMatched.length - 1] &&
|
routeMatched[routeMatched.length - 1]?.name
|
||||||
routeMatched[routeMatched.length - 1].name
|
|
||||||
) {
|
) {
|
||||||
printPageAdminLog &&
|
printPageAdminLog &&
|
||||||
console.log(
|
console.log(
|
||||||
|
|||||||
Reference in New Issue
Block a user