Closed GrandpaRex closed 1 year ago
Why did you close it? @GrandpaRex -- I don't think this would speed up the code though. A dictionary type of table seems to be faster than looping through and looking for a value
I've got to adjust a few functions to reflect the changes. I noticed the issue last night when I was testing will resubmit it when I've made the changes
I've got to adjust a few functions to reflect the changes. I noticed the issue last night when I was testing will resubmit it when I've made the changes
I would also prove out that your changes actually are quicker. In my experience, looping through a table for a value is much more inefficient than having a key-value pair in a table. Thanks for trying to improve the codebase though :)
Gotcha, I haven't thought about speed more it was easier to loop a search of id key against value. It could be my inexperience in coding but I will run benchmarks on both
Adjusted the GetGuildRoleList function to put the role names and ids into a key value table so that each role name and role id is listed under the keys "name" and "id". This allows for easier looping of these values.
Added the and member.code ~= 204 to the AddRole and RemoveRole functions to eliminate Ok- No Content error code returns on these