FIX: don't include last_wiki_edit when there's no revision
This commit is contained in:
parent
0096ee40da
commit
a6fc42753c
|
@ -359,7 +359,9 @@ class PostSerializer < BasicPostSerializer
|
|||
end
|
||||
|
||||
def include_last_wiki_edit?
|
||||
object.wiki && object.post_number == 1
|
||||
object.wiki &&
|
||||
object.post_number == 1 &&
|
||||
object.revisions.size > 0
|
||||
end
|
||||
|
||||
private
|
||||
|
|
Loading…
Reference in New Issue