summaryrefslogtreecommitdiffstats
path: root/model/post.go
diff options
context:
space:
mode:
Diffstat (limited to 'model/post.go')
-rw-r--r--model/post.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/model/post.go b/model/post.go
index 5578514b5..e66009dd6 100644
--- a/model/post.go
+++ b/model/post.go
@@ -112,6 +112,10 @@ func (o *Post) IsValid() *AppError {
return NewAppError("Post.IsValid", "Invalid filenames", "id="+o.Id)
}
+ if utf8.RuneCountInString(StringInterfaceToJson(o.Props)) > 8000 {
+ return NewAppError("Post.IsValid", "Invalid props", "id="+o.Id)
+ }
+
return nil
}