Why did you change the check to be $all_bundles instead of $bundles?