fix select behavior