I really do not like $result = false glued with foreach() in this case.