mirror of
https://github.com/wassname/talk.git
synced 2026-07-13 17:45:56 +08:00
Body Count (#1969)
* fix: adjusted beheviour of body count * fix: updated translation @okbel
This commit is contained in:
@@ -343,6 +343,20 @@ class ErrCommentTooShort extends TalkError {
|
||||
}
|
||||
}
|
||||
|
||||
// ErrCommentTooLong is returned when the comment is too long.
|
||||
class ErrCommentTooLong extends TalkError {
|
||||
constructor(length, allowed) {
|
||||
super(
|
||||
'Comment was too long',
|
||||
{
|
||||
translation_key: 'COMMENT_TOO_LONG',
|
||||
status: 400,
|
||||
},
|
||||
{ length, allowed }
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
// ErrAssetURLAlreadyExists is returned when a rename operation is requested
|
||||
// but an asset already exists with the new url.
|
||||
class ErrAssetURLAlreadyExists extends TalkError {
|
||||
@@ -413,13 +427,15 @@ module.exports = {
|
||||
ErrAssetURLAlreadyExists,
|
||||
ErrAuthentication,
|
||||
ErrCannotIgnoreStaff,
|
||||
ErrCommentTooShort,
|
||||
ErrCommentingDisabled,
|
||||
ErrCommentTooLong,
|
||||
ErrCommentTooShort,
|
||||
ErrContainsProfanity,
|
||||
ErrEditWindowHasEnded,
|
||||
ErrEmailAlreadyVerified,
|
||||
ErrEmailTaken,
|
||||
ErrEmailVerificationToken,
|
||||
ErrHTTPNotFound,
|
||||
ErrInstallLock,
|
||||
ErrInvalidAssetURL,
|
||||
ErrLoginAttemptMaximumExceeded,
|
||||
@@ -441,5 +457,4 @@ module.exports = {
|
||||
ErrSpecialChars,
|
||||
ErrUsernameTaken,
|
||||
ExtendableError,
|
||||
ErrHTTPNotFound,
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user