Mor1arty/mike
CN-locale fork fixing file upload encoding for Chinese filenames
Mor1arty's fork appears to be a Chinese-locale deployment of the upstream legal-AI codebase. The sole tracked change is a targeted fix to the file upload middleware: multer's default latin1 interpretation of multipart filename headers is corrected by re-decoding originalname via Buffer.from(name, "latin1").toString("utf-8") in backend/src/lib/upload.ts.
No feature work, no architectural changes. One bug, one patch.
What's in it
- Chinese-language file uploads Files with Chinese characters in their names or contents now flow through intake instead of being rejected at the door.
Direction
i18nintake
Activity
Mor1arty ↗ analysis ↗ GitHub Mor1arty ↗ analysis ↗ GitHub Threads of work (detailed view)
Mor1arty stops the system from garbling non-English filenames
Upload a document with Chinese characters in its name and it used to come through as gibberish. Not anymore.
Fix multer latin1 mis-decode for non-ASCII filenames
Mor1arty's fork patches `upload.ts` to re-decode `req.file.originalname` from latin1 to UTF-8, fixing the mangled-filename bug that hits anyone uploading files with Chinese (or any non-ASCII) characters. Ten lines against multer's multipart parsing default.
Mor1arty stops the uploader from scrambling non-English filenames
A small patch fixes a bug that quietly corrupted any uploaded file whose name used characters outside the basic English alphabet.
Mor1arty stops Mike from mangling non-English filenames
Upload a document named in Chinese, Japanese, or Korean and Mike used to scramble the name on the way in - Mor1arty fixed it.
Decode upload filenames from latin1 to UTF-8
A self-maintained patch by Mor1arty fixes the upload pipeline's character-encoding assumption, so files with Chinese (and other non-ASCII) filenames no longer arrive with garbled names on the server side.
Pull requests (detailed view)
✅ Merged (1)
Mor1arty · opened 2mo ago · merged 2mo ago by Mor1arty ⛔ Closed without merge (1)
Mor1arty · opened 2mo ago · closed 2mo ago