cherry-picking bug fix from dev branch