fix for #500 and another (not yet reported) wikibug