testing the transit usage was needed when we tested also that a location was internal. Now the test is done on the warehouse presence or not It seems to be useless now. Transit location should not have any warehouse above them.    I guess you can even simplify the condition like this  ```sql  WHEN whs.id IS NOT NULL AND whd.id IS NULL THEN 'out'  WHEN whs.id NOT NULL AND whd.id IS NOT NULL THEN 'in  ```