fix crashing bug due to typo