BuildTheEarth/main-bot

Suggestions number incorrectly calculated after sub-suggestions were made

cAttte opened this issue · 1 comments

currently, if a sub-suggestion is made, the suggestion identifiers will go like this:

#200#200b#200c#203

(when the last one should, instead, be #201).

this happens because the static Suggestion.findNumber() method accounts for all suggestions, therefore interpreting #200b and #200c as #201 and #202 respectively. this can be fixed by just adding a where clause that checks for the extends column being null (as to only account for non-extending suggestions).

*fixed by 143f5db