Hi DM,
In my message reader, I have it display the upvotes, downvotes, and score as header information above the message. It was using the total_votes and upvotes properties of the message headers. Recently though, it seems those properties no longer exist in the message header objects. Has something changed recently regarding those message header properties?
In my message reader, I have it display the upvotes, downvotes, and
score as header information above the message. It was using the
total_votes and upvotes properties of the message headers. Recently
though, it seems those properties no longer exist in the message
header objects. Has something changed recently regarding those
message header properties?
Those header properties are only calculated and added the header object when using the MsgBase.get_all_msg_headers() method. Are you?
Those header properties are only calculated and added the header object when using the MsgBase.get_all_msg_headers() method. Are you?
Re: Message header total_votes and upvotes properties
By: Digital Man to Nightfox on Tue Apr 23 2019 09:25 pm
Those header properties are only calculated and added the header object when using the MsgBase.get_all_msg_headers() method. Are you?
I see where the problem is. It's due to a recent update I made to my reader. I had started using the get_index() function, thinking it would be a faster way to filter vote messages out of the list of messages, and loading only the non-vote messages for display. I suppose I'll have to just use get_all_msg_headers().
When a message is voted on, the original message header is not modified - new message headers are added and distributed over the message network(s). That's why get_all_msg_headers() is needed to tally the votes.
Sysop: | fluid |
---|---|
Location: | wickliffe, ohio |
Users: | 5 |
Nodes: | 10 (0 / 10) |
Uptime: | 203:15:44 |
Calls: | 50 |
Files: | 15,838 |
Messages: | 50,771 |