Skip to content

fix(media): require LinkedIn permalink IDs - #2684

Merged
esokullu merged 1 commit into
webbrain-one:mainfrom
alectimison-maker:fix/require-linkedin-media-id
Aug 5, 2026
Merged

fix(media): require LinkedIn permalink IDs#2684
esokullu merged 1 commit into
webbrain-one:mainfrom
alectimison-maker:fix/require-linkedin-media-id

Conversation

@alectimison-maker

Copy link
Copy Markdown
Contributor

Summary

  • require a non-empty post identifier after LinkedIn /posts/ and /feed/update/ prefixes
  • route empty LinkedIn container paths through the existing screenshot/permalink-resolution flow
  • preserve direct-download behavior for both supported LinkedIn permalink shapes in Chrome and Firefox

Problem

isDirectPublicMediaUrl treated the bare /posts/ and /feed/update/ paths as concrete public media items. Recommended downloads therefore skipped visual target resolution and could send a non-item URL to download_public_media.

LinkedIn's documented /feed/update/<activityUrn> permalink shape requires a dynamic identifier: https://learn.microsoft.com/en-us/linkedin/marketing/community-management/shares#constructing-permalinks

Testing

  • node test/run.js: 1449 passed, 1 pre-existing repository failure (package.json is 26.0.10, newest CHANGELOG.md entry is 26.0.0)
  • node test/security/injection-corpus.mjs: 60/60 checks passed
  • verified empty /posts/ and /feed/update/ paths start with screenshot preflight
  • verified /posts/<id> and /feed/update/<activityUrn> retain the direct fast path
  • Chrome/Firefox URL helpers are byte-identical

Scope

This only tightens LinkedIn's two existing permalink patterns; no other host recognition or download behavior changes.

@vercel

vercel Bot commented Aug 4, 2026

Copy link
Copy Markdown

@alectimison-maker is attempting to deploy a commit to the esokullu's projects Team on Vercel.

A member of the Team first needs to authorize it.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Tightens LinkedIn permalink detection so container paths require visual resolution while concrete posts retain direct downloads.

Changes:

  • Require identifiers after both supported LinkedIn permalink prefixes.
  • Add Chrome/Firefox coverage for direct and empty permalink paths.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
test/run.js Tests direct and empty LinkedIn permalinks.
src/firefox/src/agent/public-media-url.js Requires a LinkedIn post identifier.
src/chrome/src/agent/public-media-url.js Mirrors the Firefox URL validation change.

馃挕 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@esokullu
esokullu merged commit 95374de into webbrain-one:main Aug 5, 2026
1 of 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.

3 participants