fix bug. thanks @efleming969