Why vbulletin 4 importer exclude the firstpost?

Why the importer in vbulletin exclude the firstpost from the total_count?

https://github.com/discourse/discourse/blob/master/script/import_scripts/vbulletin.rb#L433

Most likely because the first post is used to create the topic.

But then if I have ten topic/thread with attachment just in the first post, the total_count will be zero, even though I have ten attachments. right?

1 Like

Hmm, I didn’t look closely enough. Looks like you’re right :wink:

PRs are welcome :smile:

1 Like

Ok.

While we at it, this line cause errors:

I had to modified it just like the vb5 importer:

What was the error? Did it try creating an already existing index?

Yes I did. I get the error after the second run.

ref:
https://meta.discourse.org/t/vbulletin-importer-fails/26120

Probably want to handle that better rather than just catching the exception :wink:

1 Like