Fixed bug when select method is used