Fixed some small bugs in tableView