Commit 637e212a authored by Samuel Giddins's avatar Samuel Giddins

[PodTargetInstaller] Remove code duplication

parent cdf6bb97
...@@ -182,14 +182,14 @@ module Pod ...@@ -182,14 +182,14 @@ module Pod
end end
# Set the correct device family for this bundle, based on the platform # Set the correct device family for this bundle, based on the platform
bundle_device_family_map = { device_family_by_platform = {
:ios => '1,2', :ios => '1,2',
:tvos => '3', :tvos => '3',
:watchos => '1,2' # The device family for watchOS is 4, but Xcode creates watchkit-compatible bundles as 1,2 :watchos => '1,2' # The device family for watchOS is 4, but Xcode creates watchkit-compatible bundles as 1,2
} }
if bundle_device_family_map.keys.include?(target.platform.name) if family = device_family_by_platform[target.platform.name]
c.build_settings['TARGETED_DEVICE_FAMILY'] = bundle_device_family_map[target.platform.name] c.build_settings['TARGETED_DEVICE_FAMILY'] = family
end end
end end
end end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment