mirror of
https://github.com/OpenBB-finance/OpenBB.git
synced 2026-10-29 21:42:22 +00:00
no need to return empty warnings
This commit is contained in:
@@ -231,9 +231,8 @@ class StaticCommandRunner:
|
||||
else:
|
||||
command_output = func(**kwargs)
|
||||
|
||||
command_output.warnings = (
|
||||
list(map(cast_warning, warning_list)) if warning_list else None
|
||||
)
|
||||
if warning_list:
|
||||
command_output.warnings = list(map(cast_warning, warning_list))
|
||||
|
||||
except Exception as e:
|
||||
command_output = CommandOutput(error=Error(message=str(e)))
|
||||
|
||||
Reference in New Issue
Block a user