fix bug on JS code caused by Bhimasta