mirror of
https://gitlab.com/comunic/comunicapiv2
synced 2024-11-26 07:19:23 +00:00
Can send comment images without content
This commit is contained in:
parent
4ffa8a421b
commit
aa0c9f4f6a
@ -58,7 +58,7 @@ export class CommentsController {
|
|||||||
* @param need_check True if the comment must have valid content / false else
|
* @param need_check True if the comment must have valid content / false else
|
||||||
*/
|
*/
|
||||||
private static GetCommentContent(h: RequestHandler, name: string, need_check = true) : string {
|
private static GetCommentContent(h: RequestHandler, name: string, need_check = true) : string {
|
||||||
const content = h.postContent(name);
|
const content = h.postContent(name, need_check ? 3 : 0);
|
||||||
|
|
||||||
if(need_check && !check_string_before_insert(content))
|
if(need_check && !check_string_before_insert(content))
|
||||||
h.error(400, "Please check new comment content!");
|
h.error(400, "Please check new comment content!");
|
||||||
|
Loading…
Reference in New Issue
Block a user