Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
C
cocoapods
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
gengmeiios
cocoapods
Commits
4c42f3c7
Unverified
Commit
4c42f3c7
authored
Nov 08, 2016
by
Samuel Giddins
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[SourcesManager] Remove const_missing hack
It's been months, time for this hack to go
parent
c2aa84f5
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
31 deletions
+0
-31
sources_manager.rb
lib/cocoapods/sources_manager.rb
+0
-31
No files found.
lib/cocoapods/sources_manager.rb
View file @
4c42f3c7
...
...
@@ -150,35 +150,4 @@ module Pod
UI
.
puts
(
message
)
end
end
# @!visibility private
module
SourcesManagerMissingConstant
SOURCES_MANAGER_CONSTANT_WARNINGS
=
Set
.
new
# Warn about deprecated use of `Pod::SourcesManager` and return the config's
# Source::Manager
#
# @param [#to_sym] const the missing constant
#
# @return [Pod::Source::Manager]
#
def
const_missing
(
const
)
unless
const
.
to_sym
==
:SourcesManager
&&
ancestors
.
any?
{
|
a
|
a
==
::
Pod
||
a
.
name
.
start_with?
(
'Pod::'
)
}
return
super
end
calling_line
=
caller
.
first
if
Pod
::
SourcesManagerMissingConstant
::
SOURCES_MANAGER_CONSTANT_WARNINGS
.
add?
(
calling_line
)
warn
'Usage of the constant `Pod::SourcesManager` is deprecated, '
\
'use `Pod::Config.instance.sources_manager` instead '
\
"(called from
#{
calling_line
}
)"
end
Config
.
instance
.
sources_manager
end
end
extend
SourcesManagerMissingConstant
::
Object
.
send
(
:extend
,
SourcesManagerMissingConstant
)
end
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment