From d6e154b7b32ea2ba74a91ea167b619d8226fd621 Mon Sep 17 00:00:00 2001 From: Claudio Ortolina Date: Sun, 26 Apr 2026 19:01:44 +0100 Subject: [PATCH] Remove redundant case --- lib/open_ai.ex | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/lib/open_ai.ex b/lib/open_ai.ex index 4c88a6d3..1dea0699 100644 --- a/lib/open_ai.ex +++ b/lib/open_ai.ex @@ -24,10 +24,7 @@ defmodule OpenAI do instructions = Keyword.get(opts, :instructions, "") on_chunk = Keyword.fetch!(opts, :on_chunk) - case API.chat_stream(messages, instructions, model, temperature, open_ai_config(), on_chunk) do - :ok -> :ok - {:error, _reason} = error -> error - end + API.chat_stream(messages, instructions, model, temperature, open_ai_config(), on_chunk) end @spec embeddings(String.t()) :: {:ok, [float()]} | {:error, term()}