Class: WoW::Item::Set

Inherits:
Base
  • Object
show all
Includes:
HTTParty
Defined in:
lib/wow/features/item.rb

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Base

#get, #get?, #gets

Constructor Details

#initialize(id, params = {}) ⇒ Set

Returns a new instance of Set.



21
22
23
# File 'lib/wow/features/item.rb', line 21

def initialize(id, params = {})
  super(self.class.data(id, params))
end

Class Method Details

.data(id, params = {}) ⇒ Object



26
27
28
29
# File 'lib/wow/features/item.rb', line 26

def data(id, params = {})
  params.merge!({locale: WoW.locale})
  get("/#{id}", query: params).parsed_response
end