Difference between compare with empty and an empty object

In a retrieve I found out that retrieving data with an xpath. [module.forecast_brand = $brand] [module.forecast_supplier = $supplier] Does not return the correct data if supplier is empty. I replaced it with a split on supplier != empty and [module.forecast_brand = $brand] [module.forecast_supplier = empty] That one works ok. Is this expected behavior?
1 answers

What you're actually saying if the object you are comparing with is empty, is 'this association must be empty', so yes this is expected behavior. If the object you are comparing with can be empty then you should check this beforehand.