fix: unused variable has been removed and global variable t changed to local variable.