Also added filtering for custom spaces.