fixed typo in smartIdx