Skip to content

Fix "View on GitHub" link to use repository URL#293

Merged
simonhamp merged 1 commit intomainfrom
fix-plugin-github-url
Mar 22, 2026
Merged

Fix "View on GitHub" link to use repository URL#293
simonhamp merged 1 commit intomainfrom
fix-plugin-github-url

Conversation

@simonhamp
Copy link
Member

Summary

  • Fixed Plugin::getGithubUrl() to return the stored repository_url instead of constructing a URL from the Composer package name (vendor/package), which doesn't necessarily match the actual GitHub repo
  • Made the return type nullable and hid the "View on GitHub" action when no repository_url is set
  • Added tests for the viewGithub action visibility and URL correctness

Test plan

  • Existing tests still pass
  • New test verifies the action URL matches repository_url
  • New test verifies the action is hidden when repository_url is null

🤖 Generated with Claude Code

The getGithubUrl() method was constructing a URL from the Composer
package name (vendor/package), which doesn't necessarily match the
actual GitHub repository URL. Changed it to return the stored
repository_url directly. Also hides the action when no repository
URL is set.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@simonhamp simonhamp marked this pull request as ready for review March 22, 2026 00:18
@simonhamp simonhamp merged commit 04b35f8 into main Mar 22, 2026
2 checks passed
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.

1 participant