fix assertion failure (thx abma)