I don't know array_search performance impact. Can't we use isset?