taw / magic-search-engine

Search engine for Magic cards
MIT License
47 stars 19 forks source link

Unexpected behavior with `number:x-y` and dfc #278

Closed axxroytovu closed 11 months ago

axxroytovu commented 11 months ago

When using the number:x-y search query and the card y is a dfc, it is not included in the results. Presumably this is because "16a" is larger than "16", and so is not considered to be within the range.

e.g. https://mtg.wtf/card?q=e%3Alcc+number%3A13-16+is%3Afront should return Paleontologist's Pickaxe as card 16a but does not.

taw commented 11 months ago

Yeah, current behavior is very logical, but not really very useful.

Range queries should probably just ignore all letters after the number. (I guess 20b-20e unset queries would be affected, but who really does that)

taw commented 11 months ago

Changed it so 13-16 is translated to 13-16zzz unless there's some other letters there already.