Ignore more kinds of exceptions

Stephen Paul Weber created

Change summary

web.rb | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

Detailed changes

web.rb 🔗

@@ -181,10 +181,10 @@ class Web < Roda
 			call_id,
 			body: body
 		)
-	rescue Bandwidth::ApiErrorResponseException
+	rescue Bandwidth::APIException
 		# If call does not exist, don't need to hang up or send to voicemail
 		# Other side must have hung up already
-		raise $! unless $!.response_code.to_s == "404"
+		raise $! unless [404, 409].include?($!.response_code)
 	end
 
 	def start_transcription(customer, call_id, media_url)