Improved post parent check
This commit is contained in:
parent
ce374fb9c0
commit
1a65f8dcdf
@ -9,7 +9,13 @@ func main() {
|
|||||||
defer arn.Node.Close()
|
defer arn.Node.Close()
|
||||||
|
|
||||||
for post := range arn.StreamPosts() {
|
for post := range arn.StreamPosts() {
|
||||||
if post.Parent() == nil {
|
if post.ParentID == "" {
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
|
||||||
|
obj, _ := arn.DB.Get(post.ParentType, post.ParentID)
|
||||||
|
|
||||||
|
if obj == nil {
|
||||||
color.Yellow(post.ID)
|
color.Yellow(post.ID)
|
||||||
color.Red(post.Text)
|
color.Red(post.Text)
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user