Bug Fix for Busy.org: Comment's json_metadata will not be removed anymore!

in utopian-io •  8 months ago




Pull Request


What was the issue?

As you can read here in my bug report there was an issue with comment's metadata on busy.org. If you utilize the json_metadata property of a comment, like I do for the-magic-frog.com, editing this comment on busy.org would override this data with the busy.org defaults, as you can see here.
There already was a check for isUpdating but for some reason it was ignored for the metadata. In contrast, steemit.com simply adds an app property, if not present, but doesn't touch existing metadata.



The delay between my bug report and the actual fix was due to the jsonParse helper function that had to be fixed first and I was waiting for the related PR to be merged.
At first I added an own helper function but this was then not needed anymore and the implementation is indeed more elegant than parsing the json twice.

And now a question:

Is there ANYONE else other than me who ever used the comment's json_metadata for something? I was really shocked when I noticed this bug. Someone was participating in the @grenouille's story (french version of @the-magic-frog) and his/her submission was actually upvoted the most and should have made it into the story but it didn't... It turned out that he/she edited the comment on busy.org, which removed the necessary metadata for the bot to recognize it as a story submission.
This metadata is set by the website and it contains the actual content of the submission, so it is actually only possible to edit a submission on the website anyway but... I thought it was my fault... again. I was happy to realize that I can blame someone else this time! :D

So, if there's some other project using metadata on comments, maybe they appreciate this bug fix too. :)

Authors get paid when people like you upvote their post.
If you enjoyed what you read here, create your account today and start earning FREE STEEM!
Sort Order:  

Good catch. The score given was based on the amount of work done.

Your contribution has been evaluated according to Utopian policies and guidelines, as well as a predefined set of questions pertaining to the category.

To view those questions and the relevant answers related to your post, click here.

Need help? Write a ticket on https://support.utopian.io/.
Chat with us on Discord.


Thank you @gregory.latinier for reviewing my contribution. Regarding the evaluation I'm fine with everything but this one:

How would you rate the accuracy and readability of the commit messages?
Very low - they aren't concise, descriptive or consistent at all.

Is there anything you can do about this? Because the commit messages are definitely as appropriate as it gets. There are a lot of merge commits but this is due to the long time between PR and merge and it should not be an issue. Thanks. :)


My bad for the wrong answer selected. Your commit message is fine. Don't worry this doesn't affect your final score.

Hey @mkt
Thanks for contributing on Utopian.
We’re already looking forward to your next contribution!

Want to chat? Join us on Discord https://discord.gg/h52nFrV.

Vote for Utopian Witness!