Your logic seems unnecessarily complex. You can just check if any user doesn't exist using NOT EXISTS:
NOT EXISTS
SELECT 1 FROM UNNEST(users) user_to_check WHERE NOT EXISTS (SELECT 1 FROM users u WHERE u.id = user_to_check)
2.1m questions
2.1m answers
60 comments
57.0k users