##// END OF EJS Templates
comments: fix extracing auth_user from the passed in objects. Before if auth_user is empty we could relly on INT or STR passed in
marcink -
r3026:71b96937 stable
parent child Browse files
Show More
@@ -191,7 +191,6 b' class CommentsModel(BaseModel):'
191 :param renderer: pick renderer for this comment
191 :param renderer: pick renderer for this comment
192 """
192 """
193
193
194 auth_user = auth_user or user
195 if not text:
194 if not text:
196 log.warning('Missing text for comment, skipping...')
195 log.warning('Missing text for comment, skipping...')
197 return
196 return
@@ -203,6 +202,7 b' class CommentsModel(BaseModel):'
203
202
204 repo = self._get_repo(repo)
203 repo = self._get_repo(repo)
205 user = self._get_user(user)
204 user = self._get_user(user)
205 auth_user = auth_user or user
206
206
207 schema = comment_schema.CommentSchema()
207 schema = comment_schema.CommentSchema()
208 validated_kwargs = schema.deserialize(dict(
208 validated_kwargs = schema.deserialize(dict(
General Comments 0
You need to be logged in to leave comments. Login now