Use isset instead of in_array for more performance gains