Class: Beanstalk::API::Account

Inherits:
Base
  • Object
show all
Defined in:
lib/beanstalkapp/account.rb

Class Method Summary collapse

Methods inherited from Base

add_prefix, setup

Class Method Details

.element_path(id = nil, prefix_options = {}, query_options = nil) ⇒ Object

ActiveResource 2.3.2 doesn’t support singular resources this hack make it work.



6
7
8
9
# File 'lib/beanstalkapp/account.rb', line 6

def self.element_path(id=nil, prefix_options={}, query_options=nil)
  prefix_options, query_options = split_options(prefix_options) if query_options.nil?
  "#{prefix(prefix_options)}account.#{format.extension}#{query_string(query_options)}"
end