From 6b76a7a6ff4148e24ddf4bead319b65e15fb6533 Mon Sep 17 00:00:00 2001 From: Jonathan Barket Date: Wed, 8 Feb 2012 16:27:10 -0600 Subject: [PATCH] Verifying that first / @system_data[:client] exists on initialize. --- lib/ticketmaster/common.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/ticketmaster/common.rb b/lib/ticketmaster/common.rb index dc3a30f..2eb68b7 100644 --- a/lib/ticketmaster/common.rb +++ b/lib/ticketmaster/common.rb @@ -33,8 +33,8 @@ def initialize(*options) super(first.to_hash) else @system_data[:client] = first - self.prefix_options ||= @system_data[:client].prefix_options if @system_data[:client].prefix_options - super(first.attributes) + self.prefix_options ||= @system_data[:client].prefix_options if @system_data[:client] and @system_data[:client].prefix_options + super(first.attributes) if first end end