Skip to content

Commit 89edb8d

Browse files
author
Martin Moen Wulffeld
committed
Fix crash where attrs is not defined.
1 parent bb54209 commit 89edb8d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/pipedrive/base.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ def bad_response(response, params = {})
8080
raise StandardError, 'Unknown error'
8181
end
8282

83-
def new_list( attrs )
83+
def new_list(attrs)
8484
attrs['data'].is_a?(Array) ? attrs['data'].map {|data| self.new( 'data' => data ) } : []
8585
end
8686

@@ -94,7 +94,7 @@ def all(response = nil, options = {}, get_absolutely_all = false)
9494
end
9595
data
9696
else
97-
bad_response(res, attrs)
97+
bad_response(res, options)
9898
end
9999
end
100100

0 commit comments

Comments
 (0)