Skip to content

Commit

Permalink
add logs
Browse files Browse the repository at this point in the history
  • Loading branch information
sjoerdbeentjes committed Jul 31, 2024
1 parent f84cacc commit f88f286
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/lib/find-geonetwork-instances.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
export function findGeonetworkInstances(menuTree, layerId) {
export function findGeonetworkInstances(menuTree, id) {
const geonetworkInstances = new Map()

console.log('searching for geonetwork instances with id', id)

menuTree.forEach((viewer) => {
const findInMenu = (menu) => {
const { children } = menu

if (children) {
children.forEach((child) => {
if (child.id === layerId) {
if (child.id === id) {
const { geonetwork } = viewer

if (geonetwork) {
Expand Down

0 comments on commit f88f286

Please sign in to comment.