Dinesht04 commented on PR #1402: URL: https://github.com/apache/answer/pull/1402#issuecomment-3402837204
Thank you @shuashuai for pointing it out. I have added the correct labels in case of 0, 1 or more than 1 tags. Thank you @LinkinStars for reporting the issue. I have fixed the logic in ObjectChangeTag function to check against the minimumTags instead of zero in order to escape the function. Since earlier at least 1 minimum tag was required, the behavior was to exit the function if 0 tags were sent in the update request, ie, all the tags were removed while editing. In the latest commit the function is changed to check against the minimum tags and exit if the tags sent in the request are less than the minimum number of tags. I think a good addition could be sending an error to the front-end clearly stating that the tags were not updated due to less than minimum number of tags, or maybe implementing this error and check in the front-end for better UX. But since no error was sent/shown in the previous implementation, the code in the latest commit just exits the function like before. Any feedback regarding this would be very welcome. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
