Sometimes the function should return empty list, sometimes hash