diff options
| author | Mike McQuaid | 2016-11-21 18:45:20 +0000 |
|---|---|---|
| committer | GitHub | 2016-11-21 18:45:20 +0000 |
| commit | c3f959d6af36f075600aac63f208d59c30cd602c (patch) | |
| tree | 336233a927c2be8b69f74dd704b73b3293d6ac33 /Library/Homebrew/tab.rb | |
| parent | c7267b123d38d1c96c2ca786c942255d2417cd86 (diff) | |
| parent | d07b9ed7f2e8806b1840b4f60605ef45487655e1 (diff) | |
| download | brew-c3f959d6af36f075600aac63f208d59c30cd602c.tar.bz2 | |
Merge pull request #1542 from woodruffw/deprecate-utils-json
compat: deprecate Utils::JSON in favor of corelib JSON.
Diffstat (limited to 'Library/Homebrew/tab.rb')
| -rw-r--r-- | Library/Homebrew/tab.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Library/Homebrew/tab.rb b/Library/Homebrew/tab.rb index 3bb7d8b62..28f29aaad 100644 --- a/Library/Homebrew/tab.rb +++ b/Library/Homebrew/tab.rb @@ -1,7 +1,7 @@ require "cxxstdlib" require "ostruct" require "options" -require "utils/json" +require "json" require "development_tools" # Inherit from OpenStruct to gain a generic initialization method that takes a @@ -58,7 +58,7 @@ class Tab < OpenStruct # Like Tab.from_file, but bypass the cache. def self.from_file_content(content, path) - attributes = Utils::JSON.load(content) + attributes = JSON.parse(content) attributes["tabfile"] = path attributes["source_modified_time"] ||= 0 attributes["source"] ||= {} @@ -313,7 +313,7 @@ class Tab < OpenStruct "source" => source, } - Utils::JSON.dump(attributes) + JSON.generate(attributes) end def write |
