Browse files

[LocalPod] Store the platform.

The specification class only stores the active platform symbol.
  • Loading branch information...
1 parent 5334e67 commit 405a41d7a94844e88c59b684ec074fb10d97fe13 @fabiopelosin fabiopelosin committed Jun 25, 2012
Showing with 5 additions and 7 deletions.
  1. +5 −7 lib/cocoapods/local_pod.rb
View
12 lib/cocoapods/local_pod.rb
@@ -34,6 +34,10 @@ class LocalPod
#
attr_reader :sandbox
+ # @return [Platform] The platform that will be used to build the pod.
+ #
+ attr_reader :platform
+
# @param [Specification] specification
# The first activated specification of the pod.
# @param [Sandbox] sandbox
@@ -46,7 +50,7 @@ class LocalPod
# computed values. In other words, it should be immutable.
#
def initialize(specification, sandbox, platform)
- @top_specification, @sandbox = specification.top_level_parent, sandbox
+ @top_specification, @sandbox, @platform = specification.top_level_parent, sandbox, platform
@top_specification.activate_platform(platform)
@specifications = [] << specification
end
@@ -96,12 +100,6 @@ def name
top_specification.name
end
- # @return [Platform] The platform that will be used to build the pod.
- #
- def platform
- top_specification.active_platform
- end
-
# @!group Installation
# Creates the root path of the pod.

0 comments on commit 405a41d

Please sign in to comment.