Avoid Undefined index error due to empty criteria of "type = lookup"