Skip to content
Snippets Groups Projects
Unverified Commit 02e6b732 authored by momf's avatar momf Committed by GitHub
Browse files

fix: when text is null, bug can pass validation.

fixed. (maybe?)
parent cc6fa135
No related branches found
Tags 10.26.0
No related merge requests found
......@@ -140,7 +140,7 @@ module.exports = (params, user: ILocalUser, app: IApp) => new Promise(async (res
}
// テキストが無いかつ添付ファイルが無いかつRenoteも無いかつ投票も無かったらエラー
if (text === undefined && files === null && renote === null && poll === undefined) {
if ((text === undefined or text === null) && files === null && renote === null && poll === undefined) {
return rej('text, mediaIds, renoteId or poll is required');
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment