Fix a warning in the case of checking if the stockpile has a specific good.