Bug - Fixed Wiki link for blackberry polite points to the wrong page

PeKaJe

Member
Looks like WikiUtilities.java checks if an item has an effect with the same name, by using EffectDatabase.contains(), but that one (when called with a string, as it is here) calls the version of EffectDatabase.getEffectId() that is not looking for an exact match. Since the effect of the "blackberry polite" is "blackberry politeness", a non-exact match would make it think that there was both an item and an effect with the same name, in which case the wiki link would be correct. There's likely a bunch of other situations where that would fail.
 

Theraze

Active member
Interesting hack on this based on the new category lookup code:
lookup familiar blackberry polite
 

Veracity

Developer
Staff member
What is the "link to the wiki" you are talking about?

Code:
[color=green]> lookup item blackberry polite[/color]

[color=green]> lookup effect blackberry polite[/color]
The first took me to "Blackberry polite" and the second to "Blackberry politeness".

It worked that way in the Encyclopedia, too.

Tell me how to reproduce this, please.
 

Veracity

Developer
Staff member
Looks like WikiUtilities.java checks if an item has an effect with the same name, by using EffectDatabase.contains(), but that one (when called with a string, as it is here) calls the version of EffectDatabase.getEffectId() that is not looking for an exact match.
Actually, I suspect that has been fixed.

Code:
		boolean inEffectTable = EffectDatabase.containsExactly( name );
Interesting hack on this based on the new category lookup code:
lookup familiar blackberry polite
That is a different bug. Unlike every other category, the "lookup" command simply does a wiki lookup for the string if its familiar name lookup failed. Every other category, if the local type-specific lookup fails, it shows nothing.

Revision 17438 fixes "lookup familiar" to behave like every other "lookup CATEGORY".

And I think this fixes this; we already look up effect names exactly. Possibly as a result of this, although it was not noted.
 
What is the "link to the wiki" you are talking about?

Tell me how to reproduce this, please.

Fair question. Sorry for the bad description. I believe I right-clicked in the Modifier Maximizer tab results, or maybe the Purchases tab results, and used the "Wiki description" link in the right-click dropdown.

Those places do link to the correct wiki page, now. Thanks for the fix!
 
Top