Skip to content

Conversation

@Aaditya0411
Copy link

Description

This PR adds a null-check before attaching the click handler to the project share button.

In some cases, the share button element is not present in the DOM, which caused a JavaScript error when navigator.share was available.

Changes

  • Added a safe null-check before calling addEventListener on the share button
  • Prevents runtime JS errors on the project list page

Related Issue

Fixes #6154

@Aaditya0411 Aaditya0411 requested a review from dmetzner as a code owner February 1, 2026 06:52
@Aaditya0411
Copy link
Author

Hi maintainers 👋
This is my first contribution to Catroweb.
Please let me know if any changes or improvements are required.
Thanks for reviewing!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Minor JavaScript UI improvement on project page

1 participant