Lightbox disappears on click

Problem: when a user other than Admin clicks on the lightbox (whether to comment or like an image), the lightbox disappears!

ie. Admin can comment/like on images in the lightbox with no problem but no one else can.

I’ve tried deactivating all other plug-ins and also reverting to Twenty Seventeen theme but the issue persists.

If I deactivate the lightbox, users can comment/like images without any problem but just not in the lightbox.

Using the latest versions of Wordpress, Buddypress & Buddypress Media.

Any/all suggestions gratefully received :wink:

Update: I’ve tracked down the issue here and it amounts to a custom function which hides/shows information on the page “behind” the lightbox.

Is there a way of checking whether the lightbox is activated eg. is_lightbox_active (or something similar!) so that I can check for that in my function and handle accordingly?